Tehran, Iran (CNN) -- Iran on Saturday welcomed the rescue of 13 Iranian sailors by a U.S. Navy ship, calling it a "humanitarian act."
The sailors were on a fishing boat that had been hijacked by pirates in the Arabian Sea, near the Strait of Hormuz.
According to the Navy, a helicopter from the destroyer USS Kidd spotted a suspect pirate boat alongside the Iranian vessel on Thursday. The destroyer is part of the USS John Stennis Strike Group, which moved into the Arabian Sea from the Persian Gulf last week.
As the helicopter spotted the suspect pirate ship, the Kidd received a distress call from the fishing boat's captain, saying pirates were holding him and his crew captive.
A team from the Kidd boarded the vessel, took 15 suspected pirates into custody, and freed 13 Iranian hostages, the Navy said.
A spokesman for Iran's Foreign Ministry, Ramin Mehmanparast, had positive words about the rescue when he spoke Saturday to the Arabic news network Al-Alam.
"Rescuing Iranian sailors by the U.S. was a humanitarian act and we welcome such acts," he said. "The Iranian Navy also engages in such rescue operations. It is the responsibility of all nations to rescue nationals from other countries from pirates."
The carrier strike group's presence in the Persian Gulf had drawn the ire of Iranian military officials, who said the United States should not send any more warships into the Gulf.
Iranian Brig. Gen. Ahmad Vahidi said "there is no need" for countries outside of the region to have a presence there.
"Their presence does nothing but create mayhem," Vahidi said, according to the semi-official Fars News Agency.
The suspected pirates, mostly Somalis, were taken to the Stennis to be held until a decision is made about prosecution, Pentagon spokesman Capt. John Kirby said Friday.
Pirates hijacked the fishing vessel, the Al Molai, 40 to 45 days ago, U.S. Naval Forces Central Command said in a statement. The crew was "held hostage, with limited rations and we believe were forced against their will to assist the pirates with other piracy operations," according to the statement.
The Navy team provided food, water and medical care to both the suspected pirates and the Al Molai's crew after securing the ship and ensuring everyone was safe, said Josh Schminky, a Navy Criminal Investigative Service agent aboard the Kidd.
The crew had "been through a lot," he said, adding, "We went out of our way to treat the fishing crew with kindness and respect."
Defense Secretary Leon Panetta on Friday congratulated the strike group commander, Rear Adm. Craig Faller, and his team on the rescue, saying they did the right thing.
"When we get a distress signal, we're going to respond. That's the nature of what our country is all about," Panetta said, according to Pentagon spokesman George Little.
CNN's Shirzad Bozorgmehr contributed to this report.