To prevent Windows 11 or 10 from locking itself, first disable Dynamic Lock and the "On Resume, Display Logon Screen" option ...