The next best thing other than a mod would be to use the lock command.
Skyrim how to keep npcs from opening locked doors.
For the opposite effect you can set chests doors or npcs to a locked state with a number from 1 100 representing the difficulty.
They tend to fight or wander back to their posts so thus far i ve done it by simply turning off their ai.
Had this issue in whiterun with belethor everytime.
What i m trying to do is place random npcs around my house to make it look cooler.
Away from the door and not blocking paths.
Kill look at the thing you want to kill open the console.
Now i wait on the well.
If you stand in front of the entrance or anywhere in the pathing of the npc you disrupt their routine.
I believe that with the lock command it goes lock number 1 100 where 100 requires a key.
The reason i set it to 6 is because if an npc needs to go through a door or entrance and it s being used or someone is in the way they have a small in game delay.
It would lock the door and you could unlock it with the unlock command.
Obviously nothing changes in game but i can go on thinking i wiped them out.
Works like a charm.
There are three lean tos with unowned bedrolls near the forge and a table opposite the locked entrance with a random one handed weapon on top.
Can npcs open up any locked door that they re knocked into.
There is a campfire on the walkways above near a lookout platform.
If you wait in front of a locked door for 24 hours the npc cannot open it on time because you are in the way.
The level of the lock scales with the number.
There is a back gate to the keep and rear entrance which is master locked both situated by the forge.
It all worked out for my roleplay.