Yes, it is possible.
While indeed as Islearth mentioned it is necessary to stand on a correct tile to use the key and it is impossible to force anybody to enter the boss room in case of bosses from your picture (silver, bronze, copper prison keys):
Then it is possible in case Prince Drazzak (golden prison key), where we need bigger team to defeat the boss:
Just push player on a 2nd, 3rd, 4th or 5th stone tile, stand on the 1st one and use the key. Then run away from the boss room as fast as possible.
It is very popular way to kill players, who are away from keyboard.