@outfigurable Hey there! In level 7, after you defeat the goblinks and the townspeople come out from hiding, you can help the miner break down the stone wall she is standing near. A puzzle piece is hidden behind this rock. The other puzzle piece can be found behind the mountain.
You don't need the master key to beat the final level. If you're referring to the rainbow lock, you can cut the rope it's holding with your sword.