Here are the stats at level 1 (with Expansive Mind included for Gnomes) and useful racial traits for each race as a mage:
The Human Spirit
Will of the Forsaken
In conclusion, to be fully optimized, Gnome is the best race in both PvE and PvP for the Alliance because of Expansive Mind and Escape Artist. Concerning the Horde, Troll is the best race for PvE because of Berserking and Undead is the best race for PvP because of Will of the Forsaken.
The best combination is to choose Tailoring and Engineering. Indeed, Tailoring allows you to wear Robe of the Archmage (which is BiS up to phase 4) and Bloodvine Vest, Bloodvine Leggings and Bloodvine Boots (which are BiS in phase 4 and later) while Engineering allows you to wear and use awesome items for both PvP and PvE like Goblin Sapper Charge, Thorium Grenade, Goblin Rocket Boots, Gnomish Mind Control Cap, etc.
Note that Enchanting can be a good alternative to make money. However, this is especially true if you are the designated enchanter of your guild (to be able to learn the rare formulas that drop in raids) and can be largely compensated with farming.
In any case, keep in mind that it is preferable to wait until the maximum level to learn your professions in order to have enough money to buy your riding skills and mounts. The only exceptions to that rule is Skinning (to sell leather) and First Aid (bandages are essential in PvP).
Here is a list to better understand the role of each main stats for mages:
- Intellect: Increases your maximum mana points (with 15 mana points per 1 Intellect point), your chance to score a critical hit with spells (with 1% Spell Critical Strike Chance per 59.5 Intellect points) and improves the rate at which you improve your weapon skills.
- Spirit: Increases your health regeneration (while out of combat) and mana regeneration (while not casting any spells for at least 5 seconds). Note that you will start to regenerate mana (5 mana regen per 15 Spirit points) every 2 seconds until you begin casting spells again.
- Stamina: Increases your maximum health points (with 10 health points per 1 Stamina point, except the first 20 Stamina points granting only 1 health point).
- Spell Power: Increases the damage amount of damaging spells. Note that each spell has a different coefficient, see this List of Spell-Coefficients.
- Spell Critical Strike Chance: Increases your chance to score a critical hit with spells (critical hits deal 150% the normal damage).
- Spell Hit Chance: Reduces your chance to miss spells.
- Spell Penetration: Reduces targets resistances to your spell attacks.
As a caster, note that you will always have 1% chance to miss with your spells.
The level difference between you and your target adds also further chances to miss. At maximum level, you have 4% chances to miss an enemy of the same level as you, 5% chances to miss an enemy 1 level higher than you, 6% chances to miss an enemy 2 levels higher than you and 17% chances to miss an enemy 3 levels higher than you (like raid bosses).
In conclusion and to answer the question, you will need 16% Spell Hit Chance in PvE to be capped against raid bosses and 3% Spell Hit Chance in PvP to be capped against enemy players (if they do not have any gear or talent that improves their resistances).
Note that in addition to gear parts, you can improve this stat with Elemental Precision which gives you 2% Spell Hit Chance per rank (6% when it is fully ranked) and with some enchantments available from phase 4 (two enchantments that give you 2% Spell Hit Chance in total).