Okay, I figured it out, it is actually really easy.
First you add a key via the template tool. Then you select it and open the side bar. There, under Item, you see that IsKey is checked, obviously. All you have to do is enter an ID under "Key". In my case, I chose Inn_Door_Key. That's all for the key.
[img]
http://i.imgur.com/ZaiSWgT.png?1[/img]
Secondly, you create the door. All you have to do here is, again, search for the KEY field and enter
the same ID you gave the key, so in my case Inn_Door_Key. Entering anything at all into this field will lock the door. If character has the key with the right ID in his inventory, they can open the door.
[img]
http://i.imgur.com/WnyNfHn.png?1[/img]
Also, you don't have to use a key. You can use any item, as long as it has the right ID and, if you use a non-key item, jas the box IsKey checked. Hope that helps.