$\textbf{Part 1.}$ Let $Z=\{X\in M_n(\mathbb{C});\;(*)\;tr(X^2)=(tr(X))^2\}$; since the studied relation $(*)$ is homogeneous, $Z$ is a complex algebraic cone of dimension $n^2-1$ (that is, $n^2-1$ independent complex parameters).
$\textbf{Part 2.}$ The relation $(*)$ can be written $tr(X^2-tr(X)X)=0$, that is equivalent to
there are $U,V\in M_n(\mathbb{C})$ s.t. $(**)$ $X^2-tr(X)X=UV-VU$.
Conversely, if you want to construct such matrices $X$ without using its eigenvalues, then you can do as follows -when $n\geq 3$ (the case $n=2$ has been solved by Jean Marie)-
i) Randomly choose $U,V$
ii) Solve the equation $(**)$. In general (generic choice of $U,V$) , this equation has $2,8,22,52$ solutions (pairwise opposite) when $n=3,4,5,6$.