My phone has gotten warm with some games, but never overheated. A quick Google pulled this article up which had a few reasons why your phone might be overheated that you could do something about:
I have only had a phone overheat twice. Both times was from installing questionable games that actually contained crypto miners hidden in their code. This was several years ago though and I haven't heard of it recently.