If Sly is affected by locks or doors locking, how do they protect the place they live?

It’s not so much doors locking, but about being trapped. He’s perfectly fine being in a locked room/house if it’s one that he locked from his side that he knows he can leave at any time if his choosing.

Being locked in from the other side, forcibly confined somewhere, or being otherwise unable to remove himself from environments he finds uncomfortable is the real trigger here.