The departure of Kraft Heinz CEO Bernardo Hees follows a string of headaches for the consumer packaged foods company over the last year.

Shares of Kraft Heinz rose 1.3% in morning trading Monday following the announcement that former Anheuser-Busch InBev executive Miguel Patricio, 52 years old, will replace Hees as CEO.

The iconic food company's stock, which has a market value of about $40.2 billion, has fallen more than 43% in the last year as it struggles to keep up with changing consumer tastes and stiff competition from new brands. Sales have grown stagnant, and its cost-cutting has recently fallen short, especially as commodity costs increase.

In February, the company revealed that it had received a subpoena from the Securities and Exchange Commission four months earlier related to its accounting policies and internal controls. It further disappointed investors with the news that it slashed its dividend by 36% and took a $15.4 billion write-down on Kraft and Oscar Mayer, two of its biggest brands. It also announced revenue and earnings that fell well short of Wall Street's estimates.

Four days after the batch of bad news, Warren Buffett told CNBC that Berkshire Hathaway overpaid for Kraft. Back in 2015, the billionaire CEO teamed up with Brazilian private equity firm 3G Capital to finance the merger between Kraft and Heinz. Berkshire and 3G are two of the company's biggest shareholders.

Months earlier, in August, 3G trimmed its stake in the company by 7%, bringing its total ownership to about 22%. Jorge Lemann, 3G's founder, said at the time that the company's business model of buying up strong consumer brands was facing new difficulties from upstart brands.

As a result of its troubles, Kraft Heinz has been weighing a number of divestitures, including its Maxwell House coffee business and Breakstone's sour cream and cottage cheese brand. Last November, the Capri Sun owner sold its Canadian dairy business and Indian beverage business for $1.23 billion, with the proceeds going toward paying down its debt.

After signaling that another acquisition could be on its way in early 2018, the company passed on the opportunity to bid on Pinnacle Foods, which was instead snapped up by Conagra Brands. And amid speculation that Kraft Heinz could buy Campbell Soup, Hees told analysts that the company didn't want any long-term regrets when it comes to mergers and acquisitions.