ISTANBUL -- A Turkish court has rejected an appeal by U.S. pastor Andrew Brunson to be released from house arrest as his trial on terror and espionage charges continues. Brunson's lawyer, Ismail Cem Halavurt, told the Reuters news agency that he was notified on Tuesday of the court's decision. Turkey's state-run Haber TRT television also reported that the court had rejected the appeal.

The decision comes days after Turkey's president said the country would not back down if the United States imposes sanctions in the mounting diplomatic dispute over the evangelical pastor from North Carolina.

Speaking privately to journalists late Saturday, President Erdogan broke his silence on the crisis, saying the U.S. can't use sanctions to make Turkey back down.

Get Breaking News Delivered to Your Inbox

U.S. President Donald Trump announced possible "large sanctions" against the NATO ally on Thursday in retaliation for the treatment of Brunson, who was detained in the aftermath of a failed 2016 coup against Turkey's government.

The United States will impose large sanctions on Turkey for their long time detainment of Pastor Andrew Brunson, a great Christian, family man and wonderful human being. He is suffering greatly. This innocent man of faith should be released immediately! — Donald J. Trump (@realDonaldTrump) July 26, 2018

Brunson denies the charges.

Erdogan says he never used Brunson as a bargaining chip, although he previously linked Brunson's return to the U.S. extradition of cleric Fethullah Gulen, whom Ankara holds responsible for the failed coup. Gulen denies involvement.

"He is suffering greatly. This innocent man of faith should be released immediately!" the president said of Brunson on Saturday, in a tweet from aboard Air Force One as he flew to Iowa for an event.

Mr. Trump said on Twitter last week that the pastor's detention was "a total disgrace." One of Brunson's attorneys is Jay Sekulow, who also represents Mr. Trump in the Russia investigation.

Turkey's foreign minister, Mevlut Cavusoglu, quickly responded, also via Twitter: "No one dictates Turkey. We will never tolerate threats from anybody. Rule of law is for everyone; no exception."

Ministry of Foreign Affairs spokesperson Hami Aksoy added in a separate statement. "In order to improve its relations with the United States, our country has displayed necessary political will and did its part more than enough. It is impossible to accept the U.S. Administration's threatening messages, which totally disregard our alliance and friendly relations between our countries."

Brunson's next court date is scheduled for Oct. 12, according to Reuters.