My 2013 iMac running Mojave 10.14.3 has had this problem for a number of years and spans a few OS upgrades. When in locked mode, the screen can stay lit indefinitely, until I hit Esc.
Behavior is like this. I lock my Mac, or just walk away from it until it locks itself up. I touch my touchpad or press any key to light up the screen. The screen will the stay lit - for ever. I have to manually hit escape to put it back to sleep.
My settings: I have screen saver on (10 minutes). In Power Savings, I have standard options. These are checked: Put hard disks to sleep Enable Power Naps
What can I do to fix this?