Presumably $A,B,C$ are real symmetric matrices. As $B$ is positive definite, a necessary condition for $A=CBC$ is that $A$ is positive semidefinite. Suppose so. Then $A$ can be orthogonally diagonalized. Therefore, WLOG, we may assume that $A=D\oplus0$ for some real diagonal matrix $D$ with positive diagonal entries. Since $D\oplus0=CBC$, $B$ is positive definite and $C$ is symmetric, $C$ must be of the form $\tilde{C}\oplus0$, where $\tilde{C}$ is a symmetric matrix of the same size as $D$. So, WLOG, we may assume further that $A=D$ is a positive diagonal matrix. Now $A=CBC$ implies that $I = (A^{-1/2}CA^{-1/2})(A^{1/2}BA^{1/2})(A^{-1/2}CA^{-1/2})$. So we may assume further that $A=I$. But then $I=CBC$ means $B=C^{-2}$. That is, $C^{-1}$ is a symmetric square root of $B$. Hence, if $B$ can be orthogonally diagonalized as $B=Q\Sigma Q^T$, then $C=Q\Sigma^{-1/2}\Lambda Q^T$ where $\Lambda$ is any diagonal matrix with each diagonal entry equal to $\pm1$. In other words, $C$ is never unique in this reduced case. Turn back to the original case, we see that a solution $C$ always exists iff $A$ is positive semidefinite and the solution is not unique if $A\not=0$.
Edit: Since positive semidefinite square roots of positive semidefinite matrices are unique, if $C$ is required to be positive semidefinite, the above argument shows that it is uniquely determined by
$$C = A^{1/2} (A^{1/2}BA^{1/2})^{-1/2} A^{1/2},$$
where all square roots here are positive semidefinite square roots. (The answer by achille hui gives $C = \sqrt{B}^{-1} \sqrt{ \sqrt{B} A \sqrt{B} } \sqrt{B}^{-1}$. Since $C$ is unique, the two formulae actually produce the same matrix.)
When the assumption that $B$ is positive (or negative) definite is removed, things get nastier. When $B$ is nonsingular and indefinite, $C$ may not be unique even if we impose the condition that $C$ is positive semidefinite. For example,
$$
\begin{pmatrix}3&-1\\-1&3\end{pmatrix}
\begin{pmatrix}1\\&-1\end{pmatrix}
\begin{pmatrix}3&-1\\-1&3\end{pmatrix}
=
(\sqrt{8}I)
\begin{pmatrix}1\\&-1\end{pmatrix}
(\sqrt{8}I)
$$
When $B$ is singular, $C$ simply cannot be unique because its restriction on the kernel of $B$ can be taken to be any self-adjoint operator.