To jump out to the frying pan into the fire :
From a bad, stressful, or dangerous situation into one that is even worse.
Those poor refugees escaped the famine but ended up in a war zone—out of the frying pan into the fire.
I thought my old job was stressful, but my new one is 10 times worse. It's like going out of the frying pan and into the fire.
( https://idioms.thefreedictionary.com/jump+out+of+the+frying+pan+into+the+fire )
To put yourself in someone's shoes :
To imagine oneself in the situation or circumstances of another person, so as to understand or empathize with their perspective, opinion, or point of view.
Before being quick to judge someone for their actions, you should always try to put yourself in their shoes. Everyone is human, after all.
( https://idioms.thefreedictionary.com/put+yourself+in+someone%27s+shoes )