Two children have been beaten to death in India after they were seen defecating in the open near a village council building, police say.

The victims, a 12-year-old girl named Roshni and Avinash, a boy aged 10, were cousins from the Dalit (formerly Untouchable) community. Two men, brothers from the upper-caste Yadav community, have been arrested on suspicion of murder.

The attack took place at around 6.30am on Wednesday in the village of Bhavkhedi, Madhya Pradesh state, at almost the precise moment when - 7,500 miles away in New York - India’s prime minister Narendra Modi was being honoured by the Bill and Melinda Gates Foundation for his work to eliminate open defecation.

The family of the victims in the Bhavkhedi attack told reporters they have no toilet in their home, and that despite being eligible have been unable to access funds to build one under Mr Modi’s flagship Swachh Bharat - or Clean India - programme.

They, like millions of others living across India, had no choice but to defecate in public, a practice which is known to put women and children at risk.

Police believe the children’s attackers took pictures of them on their mobile phones before “beating them mercilessly with lathis [sticks] resulting in their death,” local station chief RS Dhakad told the Hindustan Times.

The children were rushed to hospital, but declared dead on arrival.

Avinash’s father, a labourer named Manoj Balmiki, said Dalits faced abuse and discrimination in the village and that the two arrested brothers had already scolded the children on other occasions in the past.

He said he had previously clashed with the pair, named by police as Hakim Yadav and Rameshwar Yadav, after cutting the branch of a tree next to a field owned by the brothers.

“There is a lot of untouchability issues in our village,” Balmiki, 32 told Reuters, adding that previous altercations between the two families had involved “casteist slurs”. “Our children cannot play with their children,” he said.

Police superintendent Shivpuri Rajesh Chandel said investigations were ongoing into “if the murder is related to superstition” linked to open defecation, “or untouchability”. The case is being treated as a possible violation of laws designed to protect Dalits and other caste and tribal communities subjected to discrimination.

But the killings also highlight the shortcomings of the government’s sanitation programme, launched after Mr Modi’s first election victory in 2014, with the aim of making the whole of India “open defecation free” by 2 October 2019 - the imminent 150th anniversary of Mahatma Gandhi’s birth.

The government says it has helped build more than 100 million household toilets in the past five years, and a tracking website for the Swachh Bharat programme claims nearly 600,000 villages have achieved “open defecation free” status.

Bhavkhedi itself was declared “open defecation free” in 2018, according to Anugraha P, the district's top civil servant.

Yet civil society groups have criticised the government’s record keeping track of its own progress, saying that plenty of households in rural areas still remain without access to toilets.

A January 2019 study by the independent Research Institute for Compassionate Economics (RICE) found that as many as 23 per cent of rural schools surveyed had toilets that were unusable due to lack of water supply or failure to keep up maintenance. The study concluded that as much as 44 per cent of the rural population across four states “still defecate in the open”.

During Tuesday night’s event with Mr Modi in New York, at which the prime minister was given one of four 2019 Global Goalkeeper Awards, Bill Gates admitted that “managing human waste is one of the world's oldest and toughest challenges”, before saying India’s efforts could be a “model” for other to follow.