If you solve the following system of equations by substitution, which statement is true?

x = z
x - 2y + z = 6
2x + y - 2z = 1
A. You can substitute z for x into the second and third equations.
B. You can substitute x for z into the second and third equations.
C. Both methods will work
D. Neither methods will work

My answer is C since the first equation stated that x=z. I just wanted to make sure it was right.