This is an expression mainly used in informal contexts. When you say that an accountant has cooked the company’s books, what you mean is that he has changed the figures in the ledger in order to cheat or deceive people. Companies, which are in the red, often resort to this, in order to show that they are in good financial position. When you cook the books, you falsify the accounts. The Chairman said, “Cook the books. I want it done before the annual shareholder’s meeting.”
*Vijay was asked to resign because he refused to cook the books.