A council that sparked outrage after taking three eastern European children away from their Ukip-supporting foster parents has apologised over its handling of the case after a review concluded that mistakes were made but the decision was taken in the children's best interests.

Rotherham borough council said it accepted that the impression given was that the removal was solely because of the foster carers' membership of Ukip. "The council can confirm that membership of Ukip would not prevent any individual from being considered as a foster carer in Rotherham and could not be a reason for removing foster children from a placement," it said.

The removal of the children caused outrage across the political divide, prompting questions in parliament and providing Ukip with a boost before a parliamentary byelection in the town, where the party's candidate finished second.

The council said legal reasons continued to prevent it from releasing further details, but said it recognised there were important lessons to learn.

"As a consequence, the council has taken action to strengthen the way it makes decisions, communicates and shares information," it said. "The council would again like to thank all the foster carers in our community for the devotion they show in looking after some of the most vulnerable children in the borough."

In November after the case made national headlines, the council's strategic director of children and young people's services, Joyce Thacker, told the BBC that her decision had been influenced by Ukip immigration policy, which she said called for the end of the "active promotion of multiculturalism".

Sources close to the case subsequently told the Guardian that there were multiple legal and social reasons why the council wanted to ensure the children be placed with foster parents who spoke their own eastern European language.

The placement with the Ukip-supporting foster couple was not intended to be long-term. It was an emergency move amid allegations that the children's birth father had sexually abused two of his daughters and had held a knife to his wife's head while she was holding their baby. According to the birth parents, the children were taken in a raid by police and social workers last year.