The first sentence of your question is easy to solve:
thats all for both cases in your first code-box. You don't need to destroy the session manually, when you use the username for the sessionname. This destroys the session automatically, when $username is different to the sessionname.
(look at: php.net
But this means for your second sentence of your question that this is quite harder to reach.
In this case you need to overwrite the SessionHandler
] or its interface.
Maybe think about a static sessionname and set the username as a cookie or in db (as user_id).