[guided]The first task is to build vectors whose inner products reproduce the entries of $C$. Define
\begin{align*}
b: \mathbb{R}^d \times \mathbb{R}^d \to \mathbb{R}, \qquad b(x,y)=x^\top C y.
\end{align*}
The symmetry of $C$ makes $b$ symmetric, and positive semidefiniteness of $C$ gives $b(x,x)\geq 0$ for all $x \in \mathbb{R}^d$.
If $C$ is not positive definite, some nonzero vectors may have zero $b$-length. We remove exactly those directions. Define
\begin{align*}
N=\{x \in \mathbb{R}^d : b(x,x)=0\}.
\end{align*}
For a positive semidefinite bilinear form, the Cauchy-Schwarz inequality says
\begin{align*}
|b(x,y)|^2 \leq b(x,x)b(y,y)
\end{align*}
for all $x,y \in \mathbb{R}^d$. Thus if $x \in N$, then $b(x,x)=0$, so $b(x,y)=0$ for every $y \in \mathbb{R}^d$. This means precisely that $N$ is the radical of $b$.
Now form the quotient [vector space](/page/Vector%20Space) $H=\mathbb{R}^d/N$. Define
\begin{align*}
(x+N,y+N)_H=b(x,y).
\end{align*}
This is well-defined: changing $x$ or $y$ by an element of $N$ does not change $b(x,y)$ because every element of $N$ pairs to zero with every vector. The form is positive definite on the quotient, since $(x+N,x+N)_H=0$ means $b(x,x)=0$, hence $x \in N$, hence $x+N=0$ in $H$. Because $H$ is finite-dimensional, this inner product makes $H$ a real Hilbert space.
Finally, let $e_i \in \mathbb{R}^d$ be the $i$-th standard basis vector and define $v_i=e_i+N \in H$. Then
\begin{align*}
(v_i,v_j)_H=b(e_i,e_j)=e_i^\top C e_j=C_{ij}.
\end{align*}
Thus $C$ has been realized as the Gram matrix of $v_1,\dots,v_d$.[/guided]