Automatic locking if door is not opened

What you are describing is the “AutoLock” feature. It will lock the door after an adjustable time after unlocking (even if the door hasn’t been opened, just unlocked).

Preventing the door Locking while the door is open is already discussed here: