Julian Zelizer is a history and public affairs professor at Princeton University, editor of "The Presidency of Barack Obama: A First Historical Assessment" and co-host of the "Politics & Polls" podcast. Follow him on Twitter: @julianzelizer. The opinions expressed in this commentary are his own.

(CNN) Democrats are making a massive political mistake by calling for the end of Immigration and Customs Enforcement (ICE).

On a Saturday when Americans across the country took to the streets to protest President Donald Trump's hardline shift on immigration policy, more and more prominent Democrats -- from Sen. Elizabeth Warren to Sen. Kristin Gillibrand -- used their voices to advocate for ending ICE as we know it.

The surprise victory of Democratic congressional nominee Alexandria Ocasio-Cortez, who highlighted attacks on ICE during her campaign against incumbent New York Democrat Joe Crowley, has given further momentum to this position.

ICE was created as part of the reorganization of homeland security after 9/11. Before the horrendous attack on our soil, the Immigration and Naturalization Service, established in 1933, oversaw immigration on the border and within the country. Under the Department of Homeland Security, which was created by President George W. Bush, the immigration bureaucracy was divided up into three parts. The US Citizenship and Immigration Services handled the naturalization and immigration process, Customs and Border Protection was responsible for monitoring the border, while ICE was given authority to deal with enforcing the laws inside the country.

Read More