A Japanese man convicted of assault and theft was arrested Sunday in Yokosuka, near Tokyo, four days after he escaped attempts to take him into custody.

Makoto Kobayashi, who brandished a knife before fleeing in a vehicle when prosecution authorities tried to take him into custody on Wednesday, was apprehended while hiding at a friend's apartment in the port city around 6:40 a.m., said the Yokohama District Public Prosecutors Office. This time he did not attempt to evade capture.

Kobayashi, 43, was put on a nationwide wanted list on Thursday for obstructing officers from performing their duty after staff of the prosecutors' office and police officers visited his apartment in Aikawa, Kanagawa Prefecture, around 1 p.m. the previous day to detain him.

Kobayashi was later seen driving a car down the Tomei Expressway toward Nagoya and the vehicle was found around 11:30 p.m. Wednesday outside an apartment building in Atsugi, some 7 kilometers away from his home, where a female friend of his lives, according to local police.

Before arriving at his friend's apartment, he stopped at a convenience store in Atsugi, where a security camera captured footage of him with shorter hair and wearing different clothes, the police said.

Kobayashi had been sentenced to three years and eight months in prison for previous crimes, including theft and violation of the stimulants control law.

According to the police, Kobayashi had been a member of a group that engaged in 105 cases of theft throughout 2017, stealing valuables worth about 38 million yen ($354,000). He has told investigators he used the money for entertainment and living expenses.

His sentence was finalized in February this year after the Tokyo High Court turned down his appeal. He was out on bail while his appeal was ongoing and repeatedly ignored orders to report to authorities after his conviction was confirmed, the prosecutors' office said.

"He told me he would go to prison, so his next visit will be several years later," a 40-year-old manager of a shop which Kobayashi frequently visited said, revealing his conversation with Kobayashi at the shop around two months ago.

"I thought he had intended to pay for his crimes," the shop manager said, appearing surprised that Kobayashi had fled.

After his escape, the police looked into Kobayashi's network of friends to find him. Although he informed the police on Friday that he would turn himself in on Saturday, he did not do so, according to an investigative source.

On Sunday, Kobayashi's friend who was with him at the apartment in Yokosuka was also arrested on suspicion of harboring a criminal.

"We sincerely apologize for causing great anxiety to residents and school personnel in the area over the incident," said Ryoichi Nakahara, chief prosecutor of the Yokohama District Public Prosecutors Office, after Kobayashi was arrested.