Outgoing US Secretary of State John Kerry said relocating the US Embassy to Jerusalem could cause an "explosion" in the Middle East.