Warren Buffett's Berkshire Hathaway holds many excellent long-term investments. But that doesn't mean that it invests in every stock that the billionaire investor is a fan of. There are many stocks Buffett is fond of that aren't in Berkshire's portfolio, including Microsoft (MSFT 1.82%) and Ferrari (RACE 2.49%). Here's why these stocks are ones Buffet has mentioned as companies he liked that could also appeal to investors.

1. Microsoft

One company that seems as though it should be a slam-dunk Buffett stock is Microsoft. The business has a huge sustainable competitive advantage, or moat, which Buffett seeks out when investing in stocks. Many of its products lack significant competition, allowing the company to dominate in many areas. For example, its Office suite, which includes Microsoft Word and Excel, is unparalleled, and it's normally the default for businesses.

And over the years, the tech company has expanded its operations to get bigger and more successful. In 2016, it acquired social networking company LinkedIn, and most recently, it closed on it is acquisition of video game giant Activision Blizzard, which makes the popular Call of Duty games.

Microsoft also reports huge, consistent profits. Over the trailing 12 months, the company has posted just $77 billion in earnings on revenue of $218 billion, which equates to a profit margin of 35%. And it's not just a one-off performance, as Microsoft regularly posts strong earnings numbers.

So why isn't Microsoft in Berkshire's portfolio? The simple reason is that Buffett and Microsoft founder Bill Gates are good friends. That close association is why Buffett prefers Berkshire not hold shares of Microsoft -- so that there isn't even the appearance of any impropriety going on.

For all other investors, however, Microsoft can make for an excellent stock to buy and hold.

2. Ferrari

Another stock that should fit the billionaire investor's criteria is Ferrari. The automaker, like Microsoft, enjoys a strong brand image in its industry. When you think of Ferrari, what often comes to mind is speed and luxury. And it's that ability to create a strong image for its business that separates Ferrari from other automakers.

There's also the exclusivity and prestige that comes with owning a Ferrari that gives owners a sense of pride. Its vehicles can easily cost consumers in excess of $300,000, and Ferrari normally makes fewer than 9,000 vehicles per year.

The Italian-based company also generates significant profit margins. Its sales total 5.8 billion euros over the past four quarters, with its profit on that 1.2 billion euros -- for a profit margin of over 20%. Ferrari has consistently posted profits over the years, and that consistency is why it would be an excellent option for Berkshire.

At Berkshire's 2023 annual meeting, Buffett admitted that within the auto industry, Ferrari "is in a special place," recognizing its strong brand. But he also points to the company's relatively small sales, suggesting that Buffett may not believe the dominance is on a significant enough scale to interest him. He is also concerned about what the auto industry may look like in the future, and the difficulty in forecasting that also makes him hesitant.

There are auto stocks in Berkshire's portfolio, including General Motors and Mitsubishi, but for the most part, it isn't a huge area that the company focuses on. If it did, Ferrari would likely be in there, as this is a stock that ticks off many checkboxes for a value-oriented investor such as Buffett.

The main drawback about the stock today is that it trades at a hefty 49 times trailing earnings. But with continued growth, Ferrari's profits should improve and that multiple could very well come down. That's why for long-term investors who are willing to buy and hold for several years, this can still make for a good investment.