I assume you mean when you log into your Windows machine you're using your MS account which is tied to the old company. If they managed that account via their AD infrastructure in Azure then they should have disabled your account. Note that I'm assuming here you are using a licensed copy of Windows not tied to an MSDN account or something on the old email.
How you do this depends greatly on whether your login account is an AD account tied to the old company's AD structure (also the computer) or whether you're using a personal MS account that happens to use the name of the old company.
If this is a personal MS account you created and not managed by a company's IT:
Go to the Email & Accounts settings in Windows. Under you account settings is an option to add an account. Add your Microsoft account from there. Note that there are separate sections for email and other apps. A single "local" Windows account can be tied to multiple Microsoft accounts. Once you've associated your existing Windows account with your personal MS account then remove the other ones.
At this point you probably are still logging in using your old account. If this account was set up by you and it is just an email thing then you can also change the email address associated with the account. This is how you would migrate from one account to another. Once you've made that change (follow the help on the earlier mentioned screen) then you should be good.
If the account you log into is actually an account owned by the old company and part of their AD organization:
You'll need to remove your machine from their domain and by extension stop using the old account altogether. To do that you'll need to create a new account on Windows tied to your personal MS account. Ensure it has admin privileges and migrate any existing documents and other settings from your current login to the new account. Once you've finished all that and verified the new account is working correctly you can remove the old account from your machine.