You have to update the terraform state with the correct provider.
You can install a Kubernetes cluster on AWS using a tool called kops. kops provisions fully automated installation of cluster.
In Azure, you can create Self Hosted Linux Build agent using release pipeline (Terraform template) and override template parameter values using variables.
Terraform allows you to define and create complete infrastructure deployments in Azure. You build Terraform templates in a human-readable format that create and configure Azure resources in a consistent, reproducible manner.
Some of the errors you receive while creating infrastructure in Azure using Terraform