Although some functions can work behind a locked screen, for enterprise grade RPA you disable screen locking and secure access to the virtual environment rather than the desktop of each VM. The kind of functions that won't work with the screen locked are things like surface automation (screenshots), global clicks and keys, activating windows.