The other guy is wrong. It just takes a simple Google search to confirm this.
I've had to implement and manage these banners at almost every company I've worked for the last several years. It's EU law. Websites that operate in the EU must obtain explicit consent to use tracking cookies. The exception here would be essential cookies which are needed to provide service – although you may still need to consent to do that depending on what data the service is collecting / processing.
Some banners don't comply with EU regulation because they default checkboxes to approve cookies and the EU regulation requires "explicit consent". That said, you almost certainly won't find a major website that doesn't comply for EU visitors and where sites get this wrong it's usually not intentional and is normally because smaller companies don't have the time or resources to comply with the nuances of EU data law. The larger companies who do have the resources hire people like myself to do it for them. There's a sizeable industry around complying with EU GDPR regulation here in Europe. Companies like Usercentrics make millions charging companies for EU-compliant cookie banners, https://www.cookiebot.com/
It's not great for small businesses, but it's great if you're a larger corporate with the money for compliance or an individual riding the EU regulatory gravy train.
The regulation is only 99 articles long and full of fun legal talk if you're interested in reading it yourself. It's just one of the many documents you'll need to familiarise yourself with if you want to do business in the EU:
https://eur-lex.europa.eu/legal-content/EN/TXT/?uri=CELEX%3A...