To change the username/email that your ecobee is registered to, you'll have to reset registration. This can be done on the thermostat by going to:
MAIN MENU > SETTINGS > RESET > RESET REGISTRATION
You can also unregister your thermostat through the Web Portal. If you have multiple ecobees registered to your account, you'll have to unregister all of them in order to change your email.
1. Select the account icon in the top right corner
2. Select "My Account."
3. Select "Unregister Thermostat" from the menu on the left. Select all of the thermostats you wish to unregister, then select "Unregister" in the bottom right corner.