Locally used providers and versions

I performed certain testing to see the behavior and possible error messages that could occur when using locally Terraform executable and AzureRM provider. It looked to me the provider versioning is fully dependent on the folder/version where you put it and not the binary file itself. Namely, if I download older provider version (3.15) and put the binary in the same folder/version (3.17) in place of the newer version (newer version binary file is deleted), without changing anything in my providers configuration it seems that Terraform is unable to detect that the binary is now different version from the one that is requested through providers configuration. With Terraform executable is easy and it works if I change the version of the executable. With provider it seems that only way of identification is the naming of the folder/version where you put the binary in. The test was conducted on Linux machine and cleanup between each attempt. I used local terraform executable to perform the action and the provider was positioned in ~/.terraform.d/plugins/test-local-prov.com/local/azurerm/3.17.0/linux_amd64/terraform-provider-azurerm_v3.15.0_x5 (note the folder version and the binary name discrepancy). Main problem is that both situations performed the same with terraform init successful initialization.

The test has been conducted also by using .terraformrc CLI configuration with provider_installation block and results are the same.

Is this by design or I’m doing something wrong?