The article that you have shared is specifically for Azure AD.
Yes, you can create 1500 app roles for single application, proivded you have not created any app roles in any other applications.
Regarding Azure AD B2C,
Azure AD B2C does not currently support appRole, such as user flows or custom policy. Reference: similar answers.
However, you can use Azure AD based authentication to grant appRole because Azure AD supports appRole. First, make sure you have added appRoles in your API application's manifest, then click Managed application in local directory to go to Enterprise Applications>Users and groups>Add user/group.
Next use an Azure AD based authentication flow such as ROPC flow or auth code flow.
Parse the token and you will see your custom role.
Let me know if you have any further questions on this.
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.