Yes, all macOS devices have a built-in virus scanner by the name of XProtect.