$6$ people spread in $3$ distinguishable rooms, every room needs one person who opens the door.
There are ${6 \choose 3}\cdot 3 \cdot 2$ options to choose the three door opener persons and let them open one certain room, so that every room is opened by one person.
Further, there are then $3$ options to have all left three guys in one of the rooms, $3\cdot 2$ options to have exactly one other guy in every room, and ${3 choose 2}\cdot 3 \cdot 2$ options to have one guy in one room, two in the other and none in the last room.
So in total there are ${6 \choose 3}\cdot 3 \cdot 2 \cdot 3 \cdot 3 \cdot 2 {3 \choose 2} \cdot 3 \cdot 2$ options to have all rooms opened by exactly one person and spread the others in these rooms.
If only there are 3 people who can open the doors (only they have keys for all the rooms). There are only $3 \cdot 2 \cdot 3 \cdot 3 \cdot 2 {3 \choose 2} \cdot 3 \cdot 2$ options left, right?