The New York State attorney general’s office began inquiring in 2015 whether the foundation, which said on one of its sites that it had offices in Manhattan and the Virgin Islands, needed to register as a charity in New York. Mr. Epstein’s longtime lawyer, Darren Indyke, replied that the site was inaccurate and that the foundation was operated out of an office in St. Thomas.

Mr. Indyke, who is one of two executors of Mr. Epstein’s $577 million estate, did not respond to messages seeking comment.

Before regulators closed their inquiry, Mr. Indyke provided them with a copy of a letter the foundation received from the I.R.S. in 2000 verifying its status as a charitable tax-exempt organization. But he never disclosed that the agency had dropped the foundation from its official roll of tax-exempt organizations.

The foundation was set up as part of Mr. Epstein’s participation in a lucrative program in the Virgin Islands that offered big tax breaks to his businesses — Financial Trust and Southern Trust — in return for a philanthropic commitment to charities in the territory. One of Mr. Epstein’s sales pitches to his wealthy clients was offering tax advantage strategies that sometimes included charitable giving.

Reports from the agency that approved the tax incentive show the foundation made more than $1.8 million in donations to charities, educational scholarships and symposiums there. In an emailed statement, the Virgin Islands Economic Development Authority said the foundation was established “primarily for the purpose of making charitable contributions to the Virgin Islands community.”

But public records show it also carried out some unusual transactions.

In 2017, the foundation, also known as Enhanced Education, cut a check for $160,000 to pay fines Mr. Epstein incurred for permit violations at his private islands. Its funds also backed the causes of political officials in the Virgin Islands, including up to $30,000 to support a computer giveaway by an elected official. The foundation also contributed tens of thousands of dollars to other groups, including the territory’s chamber of commerce.

Federal investigators have taken an interest in the foundation. In August, the F.B.I. contacted the Virgin Islands Department of Planning and Natural Resources about the payment to resolve the permit violations. Agents asked whether the department had a policy prohibiting a charitable foundation from paying the penalty, said Jamal Nielsen , a spokesman for the department. He said the contribution did not violate any department rules.