Struct methods are functions attached to structs:

https://codeeval.dev/gist/d379d12ca75a4ca278f26479ae9b7eeb

The only difference is the addition of the method receiver.

It may be declared either as an instance of the type or a pointer to an instance of the type.

Since SetName() mutates the instance, the receiver must be a pointer in order to effect a permanent change in the instance.