Justice Samuel Alito Thursday said that by refusing to enforce the "Remain in Mexico" policy, the Biden administration was clearly flouting a federal law that requires migrants to be detained or deported – not released.

Alito made the comments in a dissenting opinion in the Supreme Court case Biden v. Texas, in which the court ruled 5-4 in favor of the Biden administration. Chief Justice John Roberts, joined by Justice Brett Kavanaugh and the court's three liberal members, cleared the way for President Biden to finally end "Remain in Mexico" after more than a year of trying. 

"In fiscal year 2021, the Border Patrol reported more than 1.7 million encounters with aliens along the Mexican border," Alito wrote in an opinion joined by Justices Neil Gorsuch and Clarence Thomas.

Supreme Court Justice Samuel Alito

Justice Samuel Alito said in a dissent Thursday that the Biden administration shouldn't be able to simply get rid of the "Remain in Mexico" policy. (Michael Caterina/South Bend Tribune via AP)

SUPREME COURT HANDS BIDEN VICTORY, ALLOWS END TO ‘REMAIN IN MEXICO’ POLICY

"When it appears that one of these aliens is not admissible, may the Government simply release the alien in this country and hope that the alien will show up for the hearing at which his or her entitlement to remain will be decided? Congress has provided a clear answer to that question, and the answer is no," he continued. "By law, if an alien is ‘not clearly and beyond a doubt entitled to be admitted,’ the alien ‘shall be detained for a [removal] proceeding.’"

But the government is unable to detain the massive wave of migrants coming across the border each year. Federal law provides a remedy for this problem, Alito says. The Immigration and Nationality Act (INA) says the government "may return the alien to that territory pending a [removal] proceeding" or may parole the aliens "only on a case-by-case basis for urgent humanitarian reasons or a significant public benefit."

The government and the majority argued that because the law uses the word "may," the Biden administration can remove, or not remove, migrants at its discretion. But Alito argued that the structure of the INA, written by Congress, "offered the Executive two—and only two—alternatives to detention."

Migrants in brush

A group of migrants is led out of the brush and to a main road near Hidalgo, Texas, by Texas National Guard.  (Tyler Olson/Fox News)

JUSTICE CLARENCE THOMAS WON'T BE FIRED FROM GEORGE WASHINGTON UNIVERSITY DESPITE STUDENT OUTRAGE

"The Government must either: (1) detain them, (2) return them to a contiguous foreign nation, or (3) parole them into the United States on an individualized, case-by-case basis," Alito said. "These options operate in a hydraulic relationship: When it is not possible for the Government to comply with the statutory mandate to detain inadmissible aliens pending further proceedings, it must resort to one or both of the other two options in order to comply with the detention requirement to the greatest extent possible."

Instead, Alito said, the Biden administration has decided to forego the options in the law and "release into this country untold numbers of aliens who are very likely to be removed if they show up for their removal hearings.

"This practice violates the clear terms of the law, but the Court looks the other way," he added. 

President Biden holds a press conference in Madrid at a NATO summit

President Biden's administration scored a win at the Supreme Court Thursday when it cleared the way for him to remove the "Remain in Mexico" policy. (AP Photo/Bernat Armangue)

HOW MITCH MCCONNELL PLAYING ‘LONG GAME’ SHAPED SUPREME COURT AND LED TO END OF ABORTION LANDMARK ROE

Roberts in the majority opinion strongly disagreed. He said Alito is making inferences about the law that Congress never actually put into writing. 

"The problem is that the statute does not say anything like that. The statute says ‘may.’ And ‘may;’ does not just suggest discretion, it ‘clearly connotes’ it," Roberts wrote. "If Congress had intended section 1225(b)(2)(C) to operate as a mandatory cure of any noncompliance with the Government’s detention obligations, it would not have conveyed that intention through an unspoken inference in conflict with the unambiguous, express term ‘may.’"

CLICK HERE TO GET THE FOX NEWS APP

Biden v. Texas was the final ruling the Supreme Court released on Thursday, which was the last day of its term. That makes it the final case in Justice Stephen Breyer's career. He wrote to President Biden Wednesday that he would retire effective at 12 p.m. Thursday, and Justice Ketanji Brown Jackson was sworn in at that same time.