On its own, the Tax Department’s inquiry may provide political ammunition for Mr. Cuomo more than it presents a legal peril to Mr. Trump. Even if the department found evidence of criminal behavior, it would need to refer the matter to a law enforcement agency, such as the attorney general’s office or a district attorney, for prosecution.

In June, the state attorney general sued the Trump Foundation in civil court, accusing the charity of violating campaign finance laws, self-dealing and illegally coordinating with Mr. Trump’s presidential campaign. The suit said the foundation was co-opted by the campaign during the 2016 race. Campaign staff not only directed foundation fund-raisers but also controlled who received grants, according to the lawsuit. The lawsuit sought to dissolve the foundation, recover $2.8 million in restitution and temporarily bar President Trump and three of his children from serving in leadership positions in New York nonprofits.

Administration officials would not say when the Tax Department’s investigation began, but it became public a month after the attorney general’s lawsuit.

Beyond the civil charges, the attorney general’s office has not announced a criminal investigation into the foundation, saying only that it would seek a criminal referral from a state agency at the appropriate time. But because the office’s review of the Trump Foundation is still active, the office is coordinating with the Tax Department’s inquiry, according to an official familiar with the investigation, who also requested anonymity because the investigation is active.

The Manhattan district attorney’s office is also looking into possible impropriety by the Trump Foundation, according to someone familiar with the matter.

Mr. Trump established the Donald J. Trump Foundation in 1987, when he was a New York City real estate developer, with the stated mission of collecting and maintaining money “exclusively for charitable, religious, scientific, literary or educational purposes,” either directly or by donating to other organizations. It had about $1 million in assets in 2016, according to its last I.R.S. filing. Mr. Trump was the foundation’s president until he stepped down after taking office in January 2017.

In October 2016, the New York attorney general’s office ordered the foundation to cease soliciting donations in the state, after Mr. Trump admitted he had used the foundation’s money to contribute to political causes. After the election, Mr. Trump announced he would dissolve the foundation to avoid an appearance of a conflict of interest, but the attorney general did not approve the proposal, saying the office needed to finish its investigation.