You can use the phone lightly (such as browsing the web, chatting, etc.) while charging.
However, it is recommended not to play large games while loading, nor to run multiple software at the same time.
Since the phone itself heats up when charging, playing large-scale games will cause increased heat release from the phone, which will damage normal battery life in the long run .