anyname99 If you're talking about the screen turning off by itself, it's time can be controlled from Settings > Display > Screen timeout. Unfortunately it has a max duration of 30 minutes before the screen is turned off.
If you're talking about the time it takes for the phone to ask your passcode again after a screen timeout, that can be found under Settings > Security & privacy > Device unlock > Screen lock > [Enter your password ] > Lock after screen timeout. But it too has a max duration of 30 minutes before asking your passcode again.
Neither can be completely turned off, but maybe the 30 minutes can help you get a bit closer to your goal.