First off, why are the politicians trying to close Guantanamo Bay?
Moral reasons. Guantanamo bay is obscene when it comes to basic human decency.https://en.wikipedia.org/wiki/Guantanamo_Bay_detention_camp#Criticism_and_condemnation
Fairly good video about it: https://www.youtube.com/watch?v=KEbFtMgGhPY&t=20s
Secondly, why are the US betraying their allies now? For example they refused to hand over Gulen to Turkey and they also very recently betrayed Israel by abstaining from the UN vote demanding Israel to end settlements.
About Gulen, it is obvious he had nothing to do with the failed coup in Turkey, which was made by secular anti-religion military members; Gulen is a islam conservative more radical than Erdogan, makes no sense he'd defend a secular coup lol. Gulen also asked for asylum in the US, perspectives of a free trial in Turkey isn't nearly a possibility, handing him over wouldn't go a lot along with the liberty stances of America. Plus Erdogan has made a authoritarian shift, accepting his demands would just be a "reward" for this move.
About Israel, the country has accelerated it's anti-palestinian policies lately, and pissed off America several times lately. Plus the total backing of Israel by the US under any circumstance was becoming a tougher to defend position by each day. The abstention isn't a total change of policy, but much of a way of sending a message to Israel; it's not like a lot will change because of this UN vote.
Lastly, Obama. He is leaving and wants to make his last changes, both in foreign and national policies, because he knows Trump will take rather radical changes in diplomacy when he comes to power. These last taking of positions are also for his legacy, because it's not like he was an outstanding defensor of human rights through his 8 years of presidency despite what he promissed. Little effective change is to be expected in long term foreign policy.
For your other confusions:
Why did they bring democracy to Iraq when it is a Shia majority country that would later be dominated by Iran? Couldn't they have brought in a new NATO-friendly dictator or became more friendly with Saddam?
It was a moral argument to defend the iraqi expedition Bush made. They couldn't make the American people or Nato allies accept a war to replace a dictator. Just like most US interventions made out of freedom... Becoming friendlier with Saddam was the option the US tried before when they invaded Irak in 92, didn't work so well lol.