PARIS, France — French authorities detained and charged a repentant church volunteer Sunday after he told investigators that he was responsible for an arson attack that badly damaged a 15th-century Gothic cathedral.

The man had previously been questioned and then released after the July 18 blaze that destroyed the organ, shattered stained-glass windows, and blackened the insides of the Cathedral of St. Peter and St. Paul of the western French city of Nantes.

Detained again this weekend for further questioning, the volunteer church worker admitted responsibility for the fire, said his lawyer, Quentin Chabert.

“He confessed to the allegations against him which, as the prosecutor indicated, are causing destruction and damage by fire,” the lawyer told France Info radio. “He regrets the facts. That is certain. He is in a sort of repentance.”

French media quoted the Nantes prosecutor as saying that the 39-year-old Rwandan, who’d been tasked with the job of locking up the cathedral, told the investigating magistrate that he lit three fires: on two cathedral organs and an electrical box. His motives were unknown.

The prosecutor said the arson charge is punishable by a 10-year jail term and a fine of 150,000 euros ($175,000).

Picked up immediately after the fire, held for over a day and then released, the man was detained again on Saturday morning, on the basis of evidence gathered by police forensic experts and a 20-strong team of investigators who questioned more than 30 people, the prosecutor said in a statement.

The fire broke the main stained-glass windows between the cathedral’s two towers and destroyed its main organ. Dating from the 17th century, the organ was called the “soul of the cathedral” by faithful.

The cathedral was built over five centuries and completed in 1891. The organ had previously survived a serious fire in 1972, which annihilated much of its wooden structures.