Barbados becomes republic as Prince Charles acknowledges ‘atrocity of slavery'