Donald Trump has threatened to shut down the US government for months or even years as he fights to get funding for his planned Mexican border wall.
The US president told Democrats he was also considering declaring a national emergency so he could bypass US Congress and secure the funds necessary.
Speaking at the White House, he confirmed that he had made the threats in a meeting with Democrats Chuck Schumer, Nancy Pelosi, and other congressional leaders.
The US government is now approaching its third week of partial shutdown over funding for a wall on the Mexican border.
Mr Trump has demanded $5bn (£3.95bn) of government money for the project, which he originally claimed would be funded by Mexico, but the Democrats have refused to authorise the spending.
"We made a plea to the President, don't hold millions of Americans hostage" – US House of Representatives speaker and the Senate minority leader speak after holding meeting with President Donald Trump.
— Sky News (@SkyNews) 4 January 2019
The shutdown has left 800,000 government workers unable to work or collect a salary.
Mr Schumer, the Senate minority leader, said the Democrats had asked Mr Trump to not "hold hundreds of thousands of Americans hostage" and to "open up the government" in order to continue discussions on the wall.
"We told the president we needed the government open. He resisted," he said. "In fact he said he would keep the government closed for a very long time for months or even years."
Asked if he had made the threat, Mr Trump told reporters: "Absolutely I said that. I don't think it will but I am prepared."
He added that discussions with the Democrats had been "productive" and that both sides were "on the same page" when it came to ending the government shutdown.
"It's very important that we have great border security," the president said. "I think it's going to be over with sooner than people think.
"I will do whatever we have to do. If we have to stay out for a very long time, we're going to do that."
He said he had designated a team to meet over the weekend to discuss an end to the standoff.
Democrat House Speaker Nancy Pelosi described the meeting as "lengthy and sometimes contentious" and said the parties "cannot resolve this until we open up government".
The Democrats this week took control of the House of Representatives after winning 235 seats in November's midterm elections.
More from US
On Thursday, they approved new legislation that would end the government shutdown, with a bill that would fund Homeland Security until 8 February, while not giving Mr Trump the additional money for building a border wall.
Republican Senate leader Mitch McConnell dismissed the move as "political theatre" and said the Senate would not deal with legislation likely to be vetoed by the president.