Mr. Ghasemi’s remarks, at a regular weekly news conference reported by Iranian media, did not suggest a negotiation was underway for the release of the Americans, all of them dual citizens of the United States and Iran.
Mr. Ghasemi did not identify any of them by name. At least four Americans of Iranian descent are known to be held in Iranian prisons on dubious charges.
His public acknowledgment that the imprisonment issue had been raised appeared to signal that Iranian leaders were at least open to the idea of negotiating with the Trump administration, despite its avowed hostility toward Iran.
The United States has repeatedly called for the prisoners’ release. Iran regards them as its citizens, with none of the rights to diplomatic access afforded to foreigners arrested in the country.
Iran has long used prisoners as bargaining leverage with the United States in the more than three decades of hostility that have prevailed since diplomatic relations were severed after the 1979 revolution.
When the nuclear agreement was put into effect in January 2016, Iran released a number of dual nationals from the United States that it had arrested on spying and other charges, including Jason Rezaian, who was The Washington Post’s Tehran bureau chief.
The most prominent dual nationals currently imprisoned are Siamak Namazi, a businessman who had advocated improved relations with the United States, and his father, Baquer Namazi, a former United Nations Children’s Fund official. Others include Karan Vafadari, an art gallery owner, and Afarin Niasari, Mr. Vafadari’s wife.
Another dual citizen, Robin Shahini, a San Diego State University graduate student arrested last July and later sentenced to 18 years’ imprisonment, was released on bail in March after he began a hunger strike.
The United States also has repeatedly asked Iran about Robert Levinson, a former F.B.I. agent who disappeared in Iran a decade ago. The Iranians have said they know nothing of his whereabouts or fate, despite suspicions by Mr. Levinson’s family that he is a captive.
Advocates for the Namazis have been especially outspoken about calling for their release. Last week during the Vienna meeting, Baquer Namazi’s other son, Babak Namazi, joined with their lawyer, Jared Genser, at a news conference to denounce what they called the “intense, unrelenting, cruel and inhuman treatment” of the Namazis.
Babak Namazi also said he was counting on Mr. Trump to “take personal responsibility for the lives of my father and brother.”
In a Twitter message in October, when the Namazis were both sentenced, Mr. Trump vowed, “This doesn’t happen if I’m president!”
Mr. Trump has also denounced the Iranian nuclear accord as “the worst deal ever” and has hinted that he would seek to renegotiate or scrap it. But political analysts have suggested that he will honor terms of the deal, which eased sanctions on Iran in exchange for its verifiable pledge of peaceful nuclear work.