The Trump administration is diverting millions of dollars from federal disaster relief funds so it can be used for immigration enforcement, NBC News and CNN reported Tuesday.

The news comes as Tropical Storm Dorian, expected to soon become a hurricane, bears down on the US territory of Puerto Rico.

In total, $271 million is being reallocated from various parts of the Department of Homeland Security, but the largest chunk of the money — $155 million — will come from the Federal Emergency Management Agency's disaster relief fund.

Visit Insider's homepage for more stories.

The Trump administration is diverting millions of dollars from federal disaster relief funds and using it instead to detain migrants and create temporary locations for their court hearings, multiple news outlets reported Tuesday.

In total, $271 million is being reallocated from various parts of the agency, according to the Department of Homeland Security. But the largest chunk of the money — $155 million — will come from the Federal Emergency Management Agency's disaster relief fund, NBC News and CNN reported.

The news comes as Tropical Storm Dorian, expected to soon become a hurricane, bears down on the US territory of Puerto Rico.

"This realignment of resources allows DHS to address ongoing border emergency crisis by alleviating the surge along the Nation's Southwest Border while minimizing the risk to overall DHS mission performance," DHS said in a statement.

The agency said in a press release the 2019 DHS Appropriations Act gave the authority to move the funds.

DHS officials say it's a 'must-pay' bill

Tropical Storm Dorian is pictured off the coast of Venezuela. NASA / Handout / Reuters

Read more: Immigration officers refused to let a Harvard student into the US after reportedly questioning him about his religion and his friends' anti-American social media posts

The remaining $116 million DHS funds being reallocated comes mostly from Coast Guard operations and aviation security, DHS officials told NBC News.

One official told the network that the money was being transferred immediately, and it would fund the Immigration and Customs Enforcement agency through September 30.

"We would not say this is with no risk, but we would say that we worked it in a way to … minimize the risk," the official said. "This was a must-pay bill that needed to be addressed."

The money is being used to support a controversial Trump administration program that forces some asylum-seekers to wait in Mexico while their immigration cases are resolved in the US court system.

Democrats immediately criticized the move, arguing that the agency had not demonstrated that the reallocation was necessary and that Congress had not approved it.

"I have grave concerns about DHS's proposed end-run around laws passed by Congress that would drain millions from agencies tasked with protecting the homeland from security threats and natural disasters like hurricanes and wildfires — including CBP, TSA, FEMA and the Coast Guard," Sen. John Tester of Montana told NBC News in a statement.