You don't need to transform to a matrix! I assume you know the definition of "basis of a vector space", the vector space here, being the span of the given vectors.
A basis must both span the space and be linearly independent. Here we are given that the vectors span the space so we want to find a subset that is linearly independent To do that, start from where the "a"s are numbers and the "v"s are the vectors. is an obvious solution. If it is the only solution, then the set of vectors is independent and is a basis. If not, then at least on of the "a" is not 0. Suppose it is . Then we can rewrite as and then . Since can be written as a linear combination of the other vectors, you can drop and still have the same span. Now check to see if this smaller set is independent. If not, repeat the process.
How I would do this: We are given , , and so to check for independence we should look at .
That is equivalent to the three equations 2a- b= 0, 3a+ 2b+ 7c= 0, and a+ 3b+ 7c= 0. From the first equation b= 2a. Putting that into the other two equations, 3a+ 2(2a)+ 7c= 7a+ 7c= 0 and a+ 3(2a)+ 7c= 7a+ 7c= 0. Those are the same equation and are equivalent to c= -a. So we have for any a. Therefore the vectors are dependent and cannot be a basis for a three dimensional vector space.
If I had wanted to use matrices to solve those equations, the "matrix of coefficients" would be , with each of the given vectors as a column. "Row reducing, I would divide the first row by 2 (to get "1" in the first place) then subtract 3 times the new first row from the second and subtract the first row from the third (to get "0"s below that 2). That gives . Notice that the last two rows are the same. If I subtract the second row from the third, multiply the second row by 2/7, then add 1/2 the new second row from the first, I get . That is the reduced matrix your teacher had. The fact that the last row is all "0"s tells us that the vectors are dependent.