Some owners of private companies don't see the goal of the company as profit maximization - eg SpaceX.
With a public company there's always going to be a shareholder to sue you for not maximizing profit.
https://www.litigationandtrial.com/2010/09/articles/series/s...