Boris Johnson has said he would “rather be dead in a ditch” than agree to extend Brexit, while ducking questions on whether he would resign if it was forced on him, in a sometimes rambling speech in West Yorkshire.

Johnson’s speech and subsequent media question-and-answer session at a police training college began late, appeared to be largely unscripted, and resulted in a police officer standing behind him falling ill after standing in the sun for more than an hour.

He vowed not to go back to Brussels to request a delay to Brexit beyond 31 October, despite the likelihood of him being obliged to do so by parliament, via a bill expected to pass the House of Lords on Friday. “I’d rather be dead in a ditch,” he said.

However, he was less clear on whether he would resign if he was left with only that option. “I just don’t … I really need … [the EU] cost a billion pounds a month, it achieves absolutely nothing. What is the point of further delay?” he said.

His answer to questions on his brother Jo’s resignation as an MP were also meandering and after thanking his sibling for his work as the universities minister and calling him a “fantastic guy”, he admitted Brexit “divides families”.

On the controversial sacking of 21 Tory MPs , including former chancellors Ken Clarke and Philip Hammond, after they backed legislation to stop a no-deal Brexit, he said: “Sometimes you have to deliver discipline. Discipline is always tough, but here we are, amongst a body of men and woman who know sometimes you have to administer discipline, you have to be very clear about your message, and that’s what we’re being.”

As he opened his speech, to flaunt fresh investment in the police and the recruitment of 20,000 new officers, the prime minister clumsily attempted to quote the official police caution, sought help to remember it from the ranks of police recruits standing behind him, and then appeared to lose his thread. There had been more embarrassment for Johnson earlier in the day, during walkabouts in Leeds and Wakefield, when a man approached him, shaking his hand and smiling before gently saying: “Please leave my town.” Johnson replied: “I will. Very soon.” The hashtag PleaseLeaveMyTown became the top Twitter trend in the UK on Thursday evening after the encounter. Another man told him he should not be there and should instead be in Brussels negotiating a Brexit deal.

At the end of the Q&A after his speech, a recruit behind Johnson appeared to feel faint and had to sit down. Earlier in the day

MPs later criticised Downing Street for politicising the police by using uniformed officers as the backdrop for a heavily partisan speech.

The Police Federation also criticised the move. “I am surprised that police officers were used as a backdrop for a political speech in this way,” said John Apter, the national chair of the Police Federation of England and Wales. “I am sure that on reflection all concerned will agree that this was the wrong decision and it is disappointing that the focus has been taken away from the recruitment of 20,000 officers. This is what we should be talking about – this is what is important.”

The West Yorkshire police and crime commissioner (PCC), Mark Burns-Williamson, called on Johnson to apologise. “To use police officers as the backdrop to what became a political speech was inappropriate and they shouldn’t have been put in that position.

Jo Johnson quits as MP and minister, citing 'national interest' Read more

“It clearly turned into a rant about Brexit, the opposition and a potential general election. There’s no way that police officers should’ve formed the backdrop to a speech of that nature.”

Burns-Williamson said he had expressed his concerns to the chief constable of West Yorkshire police and asked for an explanation around what happened.

The prime minister, who will try again on Monday to force a general election through a vote in parliament, said there was “a clear choice for the country” between his vow to leave the EU by 31 October and Labour’s plans.

Labour MPs were quick to criticise the prime minister for his decision to deliver his speech flanked by police officers.

Yvette Cooper MP, chair of the home affairs select committee, said: “For Boris Johnson to make so many police stop their training and work to be part of his political stunt is an abuse of power. Police officers and trainees are overstretched and need to be able to get on with their job, not have to waste time listening to Boris Johnson’s political press conference.”

Fellow committee member Stephen Doughty MP said the speech appeared a “blatant attempt to politicise our brilliant police” ahead of an election campaign, adding: “They are not political props.”

As the officer immediately behind Johnson appeared to feel faint towards the end of his speech, he turned to see what was happening and appeared ready to draw to a close, but then continued speaking for several minutes.

Much of the speech involved Johnson urging an election. “I hate banging on about Brexit. I don’t want to go about this any more,” he said. “I don’t want an election at all, but frankly I cannot see any other way. The only way to get this thing done, to get this thing moving, is to make that decision.

“Do you want this government to take us out on 31 October, or do you want Jeremy Corbyn and the Labour party to go to that crucial summit in Brussels on 17 October, effectively hand over control to the EU and keep us in beyond 31 October?

“I think it’s a no-brainer, and I’m sorry to bring this painful subject up this afternoon, but that’s the reality of what we face, and for me there can only be one way forward for our country.”

An investigation into Islamophobia in the Conservative party, which he agreed to during his leadership election campaign live on television, was described instead as a general inquiry into “all manner of racism”.

“We are going to have a general inquiry into all manner of racism and hate crime as soon as that can be got under way, but I have to tell you, we have a zero-tolerance policy towards Islamophobia and all manner of hate crime and prejudice in the Conservative party, as you can imagine,” he said.