I'm not sure the US "created" the religious extremist government in Iran. It's a complicated story. But the Shah was hated and like other similar dictators to date the US was happy to support that regime and turn a blind eye to the atrocities against the Iranian citizenry. Just like it is happy to work with other dictatorial regimes today as long as their interests align. When the revolution happened the Ayatollah was already well positioned to take advantage of the situation. Many of the people who rose up were eventually lined up against the wall and executed, like tends to happen in these revolutions.