You can change the iPhone sleep mode time by going to Settings > Display & Brightness, then selecting "Auto-Lock" and choosing a time that suits you. This will prevent the screen from turning off after a short period of inactivity, allowing you to use your iPhone without constantly unlocking it.
To change the sleep mode on an iPhone, go to Settings, then tap on "Display & Brightness", and from there, you can adjust the "Auto-Lock" period to your desired time or choose "Never" to keep the iPhone from sleeping. This allows you to customize how long the iPhone stays awake before automatically locking and going into sleep mode.
Step 1. Go to Settings on your iPhone.
Step 2. Scroll down and find Display & Brightness.
Step 3. To adjust the auto-lock time on your iPhone, tap on the Settings icon, then select Display & Brightness, and finally tap on Auto-Lock. From there, you can set the time period for your iPhone to lock automatically when it's not being used.
Step 4. To prevent your iPhone from sleeping, you can set the Auto-Lock feature to "Never".