Microsoft Office 365 for Mac is licensed by a valid Office 365 license, but we need to change it to a different user license.
Although you can sign out and sign back in with a different Microsoft account in MS Office for Mac, this only affects online services (OneDrive) and doesn't change the account which is used to license Office 365 subscription. MS Office for Mac doesn't have the "Change License" option like its Windows counterpart. The issue can be resolved by the MS Office license removal tool that can be downloaded from here. Simple run the .pkg file, follow instructions and it will remove your MS Office license. Run MS Office again and it will prompt you to enter new Office 365 login details to activate the license.
Microsoft Office 365 for Mac