Donald Trump has said that he could win the Afghanistan war “in a week” but did not want to wipe the country “off the face of the Earth”.

At the same White House, the president also made a quixotic offer to mediate the longstanding Kashmir dispute between India and Pakistan, claiming the Indian government had invited him to act as broker – a claim quickly denied in New Delhi.

The president made his remarks sitting alongside the Pakistani prime minister, Imran Khan, who is seeking to have more than $1bn in US aid restored, after Trump cut it off last year blaming Islamabad for not doing enough to fight extremism.

“The problem was Pakistan wasn’t doing anything for us. They were subversive,” he said. “To be honest, I think we have a better relationship with Pakistan right now than when we were paying that money. That money can come back.”

Trump said that the aid could be restored “depending on what’s worked out”, but claimed that US-Pakistani relations had been better since the aid, which he said was worth $1.3bn, had been cut.

'150,000 Americans couldn’t beat us': Taliban fighters defiant in Afghanistan Read more

Trump also talked about the 18-year war in Afghanistan, as US officials pursue talks with Taliban officials, with cautious support from Islamabad.

“Pakistan’s going to help us out to extricate ourselves,” Trump said at an Oval Office meeting with Khan. “We’re like policemen. We’re not fighting a war. If we wanted to fight a war in Afghanistan and win it, I could win that war in a week. But I don’t want to kill 10 million people. Afghanistan could be wiped off the face of the Earth. I don’t want to go that route.”

Trump added that there was hope that the Taliban would talk about peace in the coming days. A White House statement later acknowledged: “Pakistan has made efforts to facilitate the Afghanistan peace talks, and we are going to ask them to do more.”

It went on: “The path to a strong and enduring partnership between Pakistan and the US lies in working together to find a peaceful resolution of the conflict in Afghanistan.”

The US made its displeasure with Khan clear when he arrived over the weekend. Rather than being whisked off in a limousine, he boarded an ordinary airport shuttle. According to Pakistani press reports, there was no one from the state department to greet him as he landed. The state department has yet to respond to a request for comment.

Fawad Rehman (@fawadrehman) No US official were present to receive PM @ImranKhanPTI at IAD airport. Neither IK recieved any state protocol. pic.twitter.com/WP1rV8XfjG

At his Oval Office meeting with Trump, Khan also asked for US mediation in his country’s dispute with India over Kashmir. The US president said the Indian prime minister, Narendra Modi, had made a similar request.

“If I can help, I would love to be a mediator,” Trump said. “It is impossible to believe that two incredible countries who are very, very smart with very smart leadership can’t solve a problem like that. If you would want me to mediate or arbitrate. I would be willing to do it.”

Khan replied: “You will have the prayers of over a billion people if you can mediate or resolve this issue.”

The Indian government, however, insisted it had made no such request.

“We have seen the [president’s] remarks to the press that he is ready to mediate, if requested by India & Pakistan, on Kashmir issue. No such request has been made by [prime minister Modi] to US president,” the foreign ministry spokesman, Raveesh Kumar, said on Twitter.

“It has been India’s consistent position that all outstanding issues with Pakistan are discussed only bilaterally.”

At the White House appearance, Khan faced questions about his attacks on press freedom in Pakistan, where three television channels have been taken of the air after broadcasting a speech by an opposition leader. Khan dismissed criticism over press freedom as a “joke”.

There were also questions about the imprisonment of Shakil Afridi, a Pakistani doctor who helped the CIA run a fake vaccine programme in Abbottabad, to confirm Osama bin Laden’s presence in a walled compound there. Trump said he would raise Afridi’s case in his talks with Khan.