The UN’s newly appointed under secretary-general for global communications has been accused of an “astonishing” breach of confidentiality, after she tweeted an image of a child refugee that displayed personal details, including her family name, location and family’s phone number.

The tweet, sent by Melissa Fleming, was retweeted by UNHCR to its 2.3 million followers over the weekend before being deleted. Fleming has since told the Guardian she is trying to locate the child’s family to apologise.

Benjamin Thomas White, a historian specialising in refugees at the University of Glasgow, who alerted Fleming to the potential data breach via Twitter, has made an official complaint to the UNHCR’s inspector general’s office.

He accused Fleming and the UNHCR communication team of ignoring concerns over the privacy and safety of the child and her family, and of breaching the agency’s data protection rules.

White said: “Melissa Fleming’s original tweet was an astonishing breach of confidentiality: she disclosed a child refugee’s personal details to her 76,000 followers. The team she heads then made things much worse by retweeting them to the 2.3 million followers of the main UNHCR Twitter feed. Neither Fleming nor her team showed any consideration for the privacy and safety of this girl and her family.”

Some commentators on Twitter responded by criticising UN agencies for their “unhealthy” communications culture, and “careless” use of child images in publicity shots.

White said Fleming’s initial response to him on the social media site was inadequate because it did not acknowledge her mistake nor apologise to the girl’s family.

“It was a carefully phrased effort to limit damage to her own reputation within the UN,” he said. “It didn’t acknowledge that she had done wrong, and it didn’t apologise to the family whose confidentiality she’d breached, or say how they would be informed and if necessary protected. She said the picture was six years old. But that child will still be a child.

“There are two issues. First is the way members of the humanitarian community use pictures and videos of the people they claim they are trying to help. The way they dehumanise them or actively endanger them. It is very common.”

“You see the banner on Melissa Fleming’s feed, where children are gathered behind her, presumably those who have been ‘helped’.” It was a form of “white-saviourism” that “has been happening for decades and it still happening” he said.

Fleming, who was chief communications officer at UNHCR until Friday, when she left to take up her new post, told the Guardian she had sent the tweet to raise awareness of how child refugees were unable to access education. She said she had “immediately acknowledged my mistake” and deleted the tweet, and said she was currently trying to locate the child’s family to apologise.

Her tweet said: “Thinking of this refugee girl I once met. One of our biggest challenges is to ensure girls like her can enrol in school so they can recover from trauma and learn again.”

Later, she sent a tweet saying: “Thank you Benjamin, you are right. Just so you know, the photo is six years old. I have deleted it”.

In an email, Fleming said: “I was trying to raise awareness about the refugee children unable to access school and used this photo I took six years ago to highlight it. The family gave me consent at the time to take her photo, wanting to get the story out about their desperate situation as refugees.

“This was a temporary assistance card for newly arrived refugees from Syria. I made a mistake by publishing it without cropping out the data. I appreciated that members of the Twitter community expressed their concern and immediately acknowledged my mistake and deleted it. I am trying to locate her family to apologise.

“I have served the refugee cause for 10 years, working to build empathy in a world that increasingly treats refugees like non-humans. I am convinced that photos help generate compassion for the benefit of refugees. We always ask for their consent.”

She said accusations of “white saviour-ism” were misplaced. She had selected the photograph for her Twitter account “to show my caring for and solidarity with” Rohingya children after playing with them in camps in Bangladesh. She went on to campaign strongly with governments and donors for their education, she said.

A former UN official, who did not want to be named, said: “The UNHCR is a very publicity-hungry organisation. They have been told – just go out there and get publicity. Sometimes the publicity is not well thought-out. I would expect the head of communication to know better than to send this out.”