To set Gmail and others (yahoo mail , etc) in Windows 8 or Windows 8.1, first you must have Microsoft account and you have to add it in your Windows mail.
If you don't have, you can register at hotmail.com, live.com, or outlook.com.
The steps :
In Windows 8 or 8.1, choose Mail
Add your Microsoft account if not already
Click Add account
Choose the mail you want to add, (example: Gmail)
You will be asked for Gmail username and password ,
And then after a while you will be able to receive and send mail using Windows 8 or 8.1 mail.