Sounds like a pop up. You're safe to close the window. They just want you to install their software and then you'd actually be infected.
To be safe, I'd download Malwarebytes for Mac. It's free. Run a scan to see if there are any issues, but it sounds just like adware.
Cheers!
CrashBurner