In classical mechanics the equations of motion are ordinary differential equations, typically of order $2$, $x'' = F(x,x')$, where $x$ is a vector in $n$ dimensions.
Here $x$ and $x'$ are nothing more than labels for two independent variables, both of which are $n$-component vectors. They are just coordinates on an $n+n$ dimensional space, and could have been named $a$ and $b$. Solutions to the differential equation are paths, parameterized by time so that $x = a(t), x'=b(t)$ follow a vector field in this space that is set up to encode the equations of motion.
On the phase space (the $2n$-dimensional space just described), the functions $a$ and $b$ (sorry, $x$ and $x'$) are independent. They are defined by $a(r,s)=r$ and $b(u,g)=g$ where the notation has been chosen perversely to make a point that this is no more than book-keeping of variables.
On one solution path of the equations of motion, $x$ and $x'$, by which I mean the restriction of the functions $a$ and $b$ to the path (ignoring their values on the rest of the $2n$-dimensional space), certainly are not independent. The path is one dimensional and (at most times, for short time intervals) a typical function of the motion like $x$, $x'$, or $x^3 + e^{x'}$, will usually contain the same information as $x$ or $x'$ or the combination $(x,x')$. Any of those data can be calculated from any other.
The vector field has been set up so that on the solution path, $\large \frac{d}{dt}$ applied to $x(t)$ gives $x'(t)$, so the labels were not quite so arbitrary as previously represented.
The notation $\large \frac{dx'}{dx}$, read as differentiation of $x'$ as a function on the phase space in the $x$ direction is $0$. It is the $n \times n$ zero matrix, not the number $0$, if $x$ has more than one component.
The notation $\large \frac{dx'}{dx}$, read as a calculation on a solution path, is $x''(t)/x'(t)$ or the $n$-dimensional analogue with matrices (which is the $1\times 1$ matrix that maps $ux'(t)$ to $ux''(t)$ for all scalars $u$), and this is not $0$.