Please refer below script procedure to check windows license details and Product id information with details.
It will help you to identify whether Windows is activated or not and more details regarding Windows license status.
Run the script procedure as either "system user" and "logged in user"