In theory, yes. But there are a few caveats to that:
1. CERN wouldn’t have been able to patent anything too generalised because there was prior art (Gopher)
2. Thus if the patent was too expensive developers would have just used a similar technology (bare in mind it took quite a few years before the web to evolve from a toy, then something that companies “needed” but it wasn’t contributing massively to their bottom line, to what it is today where a great many businesses sole market is web based).
3. Even if it had somehow became part of industry standard or CERN had achieved a vague patent that prevented similar implementations from coexisting, Europe has this thing called (if I remember the acronym correctly) FRAND patents where patents which are required as part of a standard have to be fairly licensed.
None of this means CERN couldn’t have potentially made a lot from HTML & HTTP. But I also think part of the reason it was the success it was, was because it was a royalty free open specification.
Yep, I agree that any or all of those would apply (note that regarding F/RAND, a holder can refuse, and then the standard must exclude their IP) but at the same time we have seen over and over that corporations (and the nation-states that back them up) can get in really aggressive patent wars if they see fit, even over the concept of black, glossy rectangular cuboids...