Processes in Microsoft 365 for setting up Office apps, redeeming product keys, and activating licenses.
Is your niece signed in with her associated Microsoft account? Does that resolve the activation / licensing issue?
She can only sign in successfully if you shared the subscription with her using the steps at https://support.microsoft.com/en-us/accounts-billing/subscriptions/share-your-microsoft-365-subscription and if she then followed the steps to accept the invite and install; see https://support.microsoft.com/en-us/accounts-billing/subscriptions/someone-invited-you-to-share-their-microsoft-365-subscription .
If something appears to be wrong with the subscription share, you can un-invite her and then create a new invite.