Students who have teachers who look like them do better in school, study finds