If you are using a different AppleID, you will need to de-register your mobile phone number from your old AppleID account:
Deregister iMessage on your iPhone or online – Apple Support
Once de-registered, you’ll be able to register your phone number against your new AppleID.
In the majority of cases, creating and using an entirely different AppleID not recommended - as you’ll lose access to any paid Apple Apps, Subscriptions and Services purchased from your old AppleID. All purchases are permanently tied to the AppleID account from where the purchase is made - and cannot be transferred. All of your devices should be signed-in with the same AppleID.
Your AppleID is the key to Apple Services. The account will generally be kept through your lifetime, updating your primary email address (this being the username with which you sign-in to iCloud and other Apple Services) as necessary. Similarly, you should keep your secondary (recovery) email addresses and trusted telephone numbers up to date - as these may be needed if you should ever lock-out your account.
For info:
Change your Apple ID - Apple Support
Change your Apple ID password – Apple Support
What to do after you change your Apple ID or password - Apple Support