This is a fairly common scan to let you think that you have a virus when you don't. So you follow the instructions and you get one. I see it all the time in my business. The problem is that ads from the companies, such as Google Ads, aren't necessarily checked for appropriateness. These ads generate pop-ups and attempt to deceive you into downloading their software, even getting you to buy it, in an attempt to actually infect your computer or at least to get you to pay them for useless software.
I fixed a computer for a client that saw a message indicating that the site he was surfing wasn't safe, he paid Cyber Security $79.00 to install their software, and the problem still wouldn't go away.
Don't trust any pop-ups that indicate you are infected. Run your own anti-virus software and check for yourself. Google the phrases used in the pop-ups and see if there are complaints and/or removal instructions associated with the pop-ups you are encountering.
Microsoft.com has very good information that will help you avoid problems. Just navigate to www.microsoft.com
and click on 'Security & Updates' in the top menu. Educate yourself to avoid opening the door to infection.