Draconalis said:
Race is the term we incorrectly use for ethnicity.
Actually, you're both right.
"Race" is a way of categorizing human beings according to perceived biological or essential differences. However, every assumption ever produced by race science has been widely debunked, so you're right in that most sane people now prefer the term ethnicity to the term race. The main difference is that, unlike race, ethnicity does not generally purport to be a physical scientific term, it describes how people are socially identified by their ancestry.
So basically..
We are one
species, homo sapiens.
This species was at one point thought to be divided into a number of
races determined by physiological and innate psychological characteristics.
However, very few of these characteristics turned out to actually exist, so instead we are divided into much more nuanced and local
ethnic groups.
Racism is the (at this point very foolish) belief that races actually "exist" and that being part of a given race confers any kind of intrinsic meaning about who you are.
Most of the touchstones of fantasy were all written at a time when racism was still very much the majority position, and unfortunately while most fantasy writers were not maliciously hateful towards other races in their own personal lives, that simple fact does come out (just as it does in almost all media produced at the same time). The fact that we still identify elves and dwarves as "races" rather than "species" is an affectation which we've (perhaps unfortunately) forgotten the significance of.