Terraform has to remember which real object each block of code created, or it cannot work out what to change. The state file holds that mapping, and if it is lost, Terraform will try to create everything again. Do not keep state in Git or edit it by hand, because it can hold secrets in plain text and break easily; use a remote backend and the state commands. Expect "What is in the state file and where do you keep it?"