The definition is not something that happens in predicate logic.
The formal system itself does not know anything about the letter $\phi$. Its only symbols are the primitive ones: variable letters, constant letters, function letters, predicate letters, the various logical connectives quantifiers, and whatever punctuation (such as parentheses) one needs to put them together.
When the author defines a meaning for $\phi$, that happens outside the formal system, and merely provides him with a convenient way of speaking about particular strings of primitive symbols in a succinct and systematic way. So each time a wff involving $\phi$ appears on the page, the reader is to understand that what actually is seen by the core definitions of the formal system is the string of primitive symbols that the letter $\phi$ stands for, not the letter $\phi$ itself.
This is not very different from what happens in elementary algebra. When we set forth a fact such as $a+b=b+a$, one might ask what definition in arithmetic allows one to add the letters $a$ and $b$. But there is none; the variables live outside basic arithmetic and are never really seen by the "addition" operation. However, when we substitute whatever concrete numbers the $a$ and $b$ represent, the formula is going to represent an arithmetic calculation that can actually be carried out.