The properties of value types cannot be modified within its instance methods by default. In order to modify the properties of a value type, you have to use the mutating keyword in the instance method.
With this keyword, your method can then have the ability to mutate the values of the properties and write it back to the original structure when the method implementation ends.
If you create a constant instance and then try to use mutating method
Swift refuses to build your code again — we’re trying to call a mutating function on a constant struct, which isn’t allowed.