How to fix Error: Invalid reference - A reference to a resource type must be followed by at least one attribute access in Terraform | DevErrors