I agree with you that a black female should not have to pay to send ads to a white male for her hair weave products. FB should allow this level of segmentation and discrimination based on race for both moral and business reasons.
Housing is a regulated industry where discrimination in certain ways is not allowed. The idea is allegedly that a room is a room and a tenant is a tenant, regardless of race or age or etc. The government has decreed that housing is too important of a consumer item to allow landlords to police themselves.
Unfortunately, many landlords find ways to skirt the law.
And in the case of sub-leasing and finding roommates, discrimination is totally legal. I can make a post saying "female only". Additionally, upon an in person meeting, I can even turn away a roommate who is female but isn't Asian for example.