Chosen Solution

My son can watch Netflix YouTube and play GTA as well as fortnight but if he plays anything else it switches off after 5 minutes of play

Try replacing the thermal paste and see how that goes. If that still does not fix it then I would suspect the power supply is on its way out. Xbox One S Power Block Replacement Xbox One S Power Supply