see the answer below
Explanation:
You can use a system-assigned managed identity for a Windows virtual machine (VM) to access Azure Key Vault.
Sign in to Azure portal
Locate virtual machine VM1.
Select Identity
Enable the system-assigned identity for VM1 by setting the Status to On.

Note: Enabling a system-assigned managed identity is a one-click experience. You can either enable it during the creation of a VM or in the properties of an existing VM.
Reference:
https://docs.microsoft.com/en-us/azure/active-directory/managed-identities-azure-resources/tutorial-windows-vm-access-nonaad