"it can forbid the company to operate in that country "

What does that even mean on the internet?

IE what do you expect them to do, and why is it the company's' problem?

Do you really believe if Google, Facebook, whoever, was to close up all their physical shop in say, France, and take no affirmative steps to "operate a business" there (IE they don't try to explicitly block folks, but tell them not to do it and don't do it themselves) France would declare whatever they want to do okay?
Of course not.

It's pretty irrelevant where they do business, examples abound of countries where none of these companies have explicit presences trying to regulate them. None of this would be any different if they were entirely located, and declared all profit, inside, say, the US. The argument would be slightly more tortured, but the EU/etc would make it and do everything they could to hold these companies to it.

(and you don't want to try the "they operate a business wherever they earn profit", as this is even more fuzzy, as opinions differ on what profit is earned where, even if you ignore the tax issues. In fact, you can already see the countries don't want to make that argument because they don't like the answers it gives!).

Since Google is pretty polarizing, let's take HN instead.
Imagine someone in France files a RTBF request against HN for continuing to index an HN story about a crime they "paid their time for".

HN has no presence in France (i think! :P). Do you really believe France is going to say "yeah, you are right, do whatever you want"? That seems ... really really unlikely.

It's also pretty clearly not HN's job to say, try to deliberately exclude french citizens from participating.

So what do you want them to do, exactly?

They are kind of screwed no matter what they do[1]

The truth is, this is the problem with international legal jurisdiction in the internet world.
All countries/unions/what have you want their jurisdiction to be as expansive as possible. Historically, these jurisdiction were limited by physical borders, military might/willpower or allied treaties.

But they all (US included) see ways to expand their jurisdiction when it comes to internet companies, as their digital footprints are often much larger than their physical ones.

So, as expected, they all try to claim it, because it is to their political/legal/social/trade advantage to do so. If they don't, nobody will ever care about them at all. IE If i can easily make globally successful companies that doesn't have to care about EU law, but still derives benefit from EU citizens voluntary using it, why would any company want to care about the EU?

This is why it does not matter where they "operate a business" or any other metric you can come up with. The metric is really "able to be successful and used by citizens of X without really being subject to the direct legal jurisdiction of X". Any time this happens, X will claim, through whatever argument they can, that the company is subject to their legal jurisdiction/regulations. Because if what they really cared about was anything else, these countries, like China, would just block the website/story/whatever inside their borders! They certainly have such power. Instead, they want the foreign website to recognize and submit to their authority, so that the country/union/etc stays relevant.

It's really not about anything else, and for pretty much all of these companies, there is no real way out.

[1] This is usually the point where the argument devolves into extremism, and people suggest that if these companies simply collected no data, they would never have problems. This is, IMHO, pretty naive as well, as they have the same problems above whether they are being asked to remove data, or keep it, or what have you. The data issue is just one that happens to involve something people seem passionate about, but it is far from the only issue that arises. This is about the joy of legal jurisdiction in a world without borders. It applies equally well to things vastly unrelated to issues like RTBF.