Concerns about the banking system and a potential recession have given the market shades of 2008. Investors are uneasy and looking for the best investments to park their money.

Beverage giant Coca-Cola (KO 0.63%), a favorite of Warren Buffett's, has become a popular idea. Shares are just nine percent from their all-time highs, and near the high end of their five-year range.

Fundamentally, Coca-Cola is a great business. However, there isn't always safety in numbers. Here is why you should think twice before buying shares for yourself.

Coca-Cola is commanding a premium

Rocky markets mean that investors want to put their money in places where it's safe. Coca-Cola is just that -- at least financially. The stock is one of Warren Buffett's most significant holdings, and the company is a legendary dividend payer. It sells beverages, something everyone buys whether the economy is up or down. Coca-Cola's business will probably continue performing as it has for years, which means slow and steady growth for decades.

KO PE Ratio (Forward) Chart

KO PE Ratio (Forward) data by YCharts

The stock's popularity has driven up its price. Shares trade at a price-to-earnings ratio (P/E) of more than 23; that's a hefty premium to the S&P 500, which commands a P/E of 18 today. It seems reasonable at first glance -- analysts predict the S&P 500 will grow earnings by 2.5% in 2023, a slower rate than what analysts expect from Coca-Cola moving forward. Investors hear a household name, see Coca-Cola's solid fundamentals, and pay for the supposed sure thing.

A bull market is coming. What does that mean for Coca-Cola?

Mid-single-digit earnings growth and a 3% dividend yield add up to roughly nine percent total investment returns each year, assuming the stock's valuation doesn't change. But what if it does?

The news headlines might read like the economy is about to hit rough seas, but the storm's been ongoing for quite some time if you own growth stocks. The technology-centric NASDAQ is almost 30% off its high, and many small and medium-sized growth stocks are down 50%, 60%, and even 90% from their former highs.

I can't say for sure -- but it's highly likely, given every stock market cycle throughout history, that investors will eventually stop seeking safety and return to riskier assets like growth stocks. Not all companies will recover to 2021 highs, but those still growing with paths to profitability will become popular again. In other words, the market will cycle once more, and safe, defensive stocks like Coca-Cola won't be so appealing anymore.

So is Coca-Cola a buy?

Some stocks are in constant demand, and Coca-Cola could easily count as one. Buying Coca-Cola today might not necessarily mean you lose money, but there's a good chance that the stock pauses while profits grow and catch up to the valuation. What if Coca-Cola trades sideways (the share price doesn't go up or down very much) until the P/E falls to 20?

Analyst estimates call for earnings-per-share (EPS) of $2.60 in 2023, giving us its current P/E (23). Assuming Coca-Cola grows earnings by six percent annually, it would take until Coca-Cola earns $3.08 in 2026 to crack a P/E of 20. Does that seem like a long time? Valuations don't catch up quickly when growth is slow.

In other words, valuations matter; the stock's current valuation could mean going several years without meaningful investment returns. That doesn't sound like a great investment to me.