The move follows accusations that the social network offered tools that allow advertisers to break American anti-discrimination laws, through an ad-targeting feature described as “ethnic affinity” profiling.