And everyone keeps telling me that Apple does not get viruses.

If it is a pop-up notification in Safari browser it is not really a virus, in that case it is just an undesired notification from a real or faked McAfee we site. You can go to Safari Preferences/ Settings/ Websites / Notifications and remove all sites listed (or at least those that you do not actually want).
Install Firefox and use it as a browser to see if you still get the pop-up.
If that does not work, do you have a backup, "Time Machine" on a Mac, that pre-dates the appearance of the pop-up? If all else fails you will have to reconfigure the system back to initial state and restore the backup.
This sort of thing highlights the one of reasons why you should always have a backup.
PS. I am not a lover of Apple products but unfortunately the female side of my family is. We actually have 3 Macbooks in the house of which 2 are in use. Fortunately Windows and Android outnumber the Apple products.
