It doesn't have to, the rights you grant Github when you agree to the ToS and upload your work exist independent of any rights you might grant as part of the repo's license.
This only applies to work you have exclusive ownership over (and GH's ToS are explicit about this). You don't (legally can't) grant GH any rights to work you don't own. But you can still upload it (e.g. forked open-source code).