Well, I can assure you that I am just about certain a virus or any malicious actor is not the cause here.
If you believe the issue to be software, you can factory reset the phone or reinstall it's firmware entirely using the Windows Device Recovery Tool but if the issue persists, it is then hardware.