LILONGWE, Malawi — Madonna got approval to adopt two more children from Malawi but only after she was asked "uncomfortable questions" by a judge in the southern African country, according to a court document obtained Wednesday by The Associated Press.

Judge Fiona Mwale detailed her reasons for letting Madonna adopt the 4-year-old twin girls in a ruling on Tuesday, saying she was satisfied that Madonna "is motivated by her desire to offer a home, love, protection and guidance."

"The petitioner is a professional performer and I guarded myself against the danger of her merely reciting a well-rehearsed speech by asking her some rather uncomfortable questions to which she gave very candid answers," Mwale said in her ruling.

Madonna, who has two other adopted children from Malawi, filed for adoption in a high court in Lilongwe, Malawi's capital, on Jan. 25, court and government officials said.

She confirmed it in an Instagram post Wednesday and asked for privacy. "I can officially confirm I have completed the process of adopting twin sisters from Malawi and am overjoyed that they are now part of our family. I am deeply grateful to all those in Malawi who helped make this possible, and I ask the media please to respect our privacy during this transitional time," the post read.

When the AP last month reported that Madonna was seeking the adoption, the pop star issued a statement declaring the report as false. She said she was in the country for charity work.

Mwale said she didn't challenge Madonna, 58, on Malawi's residency requirements for adoption, saying the country's Supreme Court of Appeal had addressed the issue in the pop star's previous adoption.

"In determining her motives, I questioned the petitioner at length about the impact of her decision which could be construed as robbing Malawi of its most precious resource, its children," the judge wrote.

Madonna said the children will keep their birth names as part of an effort to preserve their identity as Malawians, and a Malawian carer will travel with the children to the United States to ease their transition, according to the ruling.

The twins were delivered by cesarean section and their mother died within a week because of complications from the birth, the court document said. The children have five older siblings and the father, who was at the Jan. 25 court hearing attended by Madonna, had remarried and was unable to provide for all his dependents, it said.

In 2006, Madonna founded the charity Raising Malawi to address the poverty and hardship endured by the country's orphans and vulnerable children.

In 2013, Malawi accused Madonna of exaggerating her contributions to the impoverished country and unreasonably demanding special treatment during a tour there. The pop star denied the accusations. On a visit to Malawi in late 2014, she met newly elected President Peter Mutharika as well as the father of her adopted, Malawi-born son.

Mwale noted that the pop star has raised $7.5 million for her latest project in Malawi, the construction of a pediatric surgery ward at Queen Elizabeth Central Hospital in Blantyre. The ward is scheduled to open early next year.