PARIS (Reuters) - A cousin of Abdel-Malik Nabil Petitjean, who was formally identified as one of the two men believed to have killed a French priest in a church last week, has been placed in preventive detention, the Paris prosecutor's office said on Sunday.

The man, identified as Farid K, 30 - born in Nancy, eastern France - was put under formal investigation on suspicion of terrorist association with a view to perpetrating a crime, the prosecutor's office said.

Another man, named as Jean-Philippe Steven J, 20, was also put under formal investigation for attempting to travel to Syria in June with Petitjean. He was also sent to preventive detention.

Knife-wielding attackers interrupted a church service in Saint-Etienne-du-Rouvray, western France, on July 26, forced 85-year-old Roman Catholic priest Father Jacques Hamel to his knees and slit his throat.

Police identified 19-year-old local man Adel Kermiche as one of the attackers. He had made failed bids to reach Syria to wage jihad, wore an electronic tag and was awaiting trial for alleged membership of a terrorist organization, having been released on bail.

They identified the second attacker as Petitjean, also 19.

Both were shot dead by the police.

Investigators are trying to determine how the two men met.

Le Parisien daily newspaper reported on Sunday they had held a conversation on July 22 on the instant messaging service Telegram.

Last week, Islamic State's affiliated news agency Amaq released a video purportedly showing Petitjean urging Muslims to destroy France.

A Syrian asylum seeker thought to be linked to the church attack, and who had been arrested last week, was released on Sunday, a source close to the investigation told Reuters.

(Reporting by Matthias Blamont; Editing by Andrew Bolton)