To confirm… You installed this add-on anti-malware app on a second and different system (a Mac), and not on this iPhone, and are getting this on an iPhone that did not have that stuff installed?
Did you also install or configure McAfee on your local Wi-Fi router, too? Does this same error happen when connected via cellular, or via an unrelated Wi-Fi network. Is this error tied to your.Wi-Fi network?
A second computer should not be involved here, not unless it is somehow still hijacking local network traffic, and a second and separate system should not be doing that. Not unless McAfee was also installed in this iPhone, or was configured on this iPhone, or was configured on a shared component such as the Wi-Fi router.