I am confused about how best to view certain kinds of variables that show up in the course of an elementary proof. For example, to prove that the square of every odd integer is odd, I would write:
Let $m \in \mathbf{Z}$ be arbitrary. Suppose $m$ is odd. Choose $k \in \mathbf{Z}$ such that $m = 2k + 1$. Then $m^2 = (2k + 1)^2 = 2(2k^2 + 2k) + 1$, so since $2k^2 + 2k \in \mathbf{Z}$, it follows that $m^2$ is odd.
The symbol $m$ is introduced as part of the technique of universal generalization; Velleman [1] describes this step as "introducing a new variable [$m$] ... to stand for an arbitrary object." The symbol $k$ is introduced as part of the technique of existential instantiation; [1] describes this as "introducing a new variable [$k$] to stand for an object for which [the predicate $m = 2k + 1$] is true."
In what sense are $m$ and $k$ variables? They do not seem to be bound variables, as they are in the scope of no quantifier. They also can't be free variables, because if they were, then, for example, the sentence being proved true after the introduction of arbitrary integer $m$ -- namely that if $m$ is odd then $m^2$ is odd -- would be a predicate and not even have a truth value; I am also obviously not free to substitute values into $m$ and $k$, if for no other reason than $m$ and $k$ are dependent.
Stoll [2] says a variable is free if it is not bound, so there is no third option.
Is it more correct to think of the phrases "let $m \in \mathbf{Z}$ be arbitrary" and "choose $k \in \mathbf{Z}$ such that ..." as introducing new constants rather than variables, as their values are fixed despite being unspecified ($m$) or unknown ($k$)? More generally, the idea of a symbol that stands for a particular but arbitrary element of some set seems incompatible with the typical description of a variable as a placeholder as seen in, e.g., Epp [3].
[1] Velleman, D. (2006). How to Prove It: A Structured Approach (2nd ed.). Cambridge: Cambridge University Press.
[2] Stoll, Robert Roth (1963). Set Theory and Logic. W.H. Freeman.
[3] Epp, Susanna S. Variables in Mathematics Education. https://condor.depaul.edu/~sepp/VariablesInMathEd.pdf
universal generalization: "for all odd $m \in \Bbb{Z}$".
existential instantiation: "there exists a $k \in \Bbb{Z}$ such that $m = 2k+1$".
These are both quantified and they are quantified in the way you recite.
It is more accurate to think of variables as variables. A statement with a universally quantified variable may be specialized, removing the universal quantifier, by replacing the occurrences of the variable with a particular member of the set from which that variable is drawn. For instance, in your proof, an equally valid set of statements is produced by replacing every instance of $m$ by "$3$" (an odd integer). Existentially quantified variables can be specialized to the value that satisfies their constraints.
When $m$ is generic (free to range over the odd integers), $k$ must be generic, since the value of $k$ is dependent on the value of $m$. (In a more pedantic setting, the dependence of $k$ on $m$ would be made more apparent by writing, for instance $k(m)$, $k_m$, or some other syntax to indicate dependency. This dependency enforces an order on the quantifiers. Equivalently, the order of the quantifiers, $\forall m \text{ odd}, \exists k \in \Bbb{Z} \dots$.) Even though $k$ is generic, in this case, we can solve for $k$ in terms of $m$: $k = \frac{m-1}{2}$. Consequently, throughout, we may specialize the variable $k$ to the value $\frac{m-1}{2}$.
When $m$ is specialized to a value, we may replace $k$ with the value that is half of one less than the value of $m$. We still end up with a valid set of statements -- this valid set of statements is the explicit proof of the oddness of the square of whatever value $m$ has taken. This last should make it clear: $m$ and $k$ are variables. For each specialization of $m$ and $k$ to (valid) values, we obtain a concrete proof. If we do not specialize, we obtain a proof that is universally quantified over $m$ and existentially quantified over $k$ (which is dependent on $m$).