President Trump’s former personal attorney Michael Cohen has agreed to cooperate with Manhattan prosecutors — and has already started meeting with them behind bars — as part of an investigation into the Trump Organization’s business dealings, sources said Wednesday.

The district attorney’s office is probing whether the president’s business operation falsified records, which would result in fines for it or possibly Allen Weisselberg, the chief financial officer, according to the sources.

Cohen, 52, agreed to take part in the investigation and was interviewed in recent weeks at Otisville Prison upstate, where he’s being held on tax evasion and bank fraud charges — and also campaign finance violations, the sources said.

Prosecutors launched the probe last month and sent subpoenas to the Trump Organization and American Media Inc., seeking documents and records related to payments made to porn star Stormy Daniels and ex-Playboy model Karen McDougal, who claim to have engaged in sexual relations with the president.

Cohen has admitted to giving the women hush money to keep the alleged hookups under wraps. Trump has repeatedly denied having the affairs. The DA’s office is looking into whether the president’s organization violated state law by falsifying business records to conceal a series of paybacks that Cohen claims to have received as reimbursement.

Prosecutors have met with the former lawyer at least once — on Aug. 20 — and he’s expected to speak with them again, according to sources.

Cohen pleaded guilty last November and was sentenced to three years in prison. His lawyer, Lanny Davis, declined to comment when reached by media outlets on Wednesday night.

Manhattan DA Cyrus Vance Jr. decided to pick up the Trump Organization probe just weeks after federal prosecutors announced they’d completed their investigation into the alleged hush-money payments. Trump lawyer Marc Mukasy blasted the move, calling it “a political hit job.”

Sources told The Post that the Cohen agreement is considered to be a match made in heaven.

“What you have here is a marriage between someone who will say anything and someone who will investigate anything,” a source explained.

Federal prosecutors in New York and Washington spent months probing the payments to see if any campaign finance laws were broken. They finally closed their investigation in July.