Your idea to check ranks first is good. Since by that check the existence of the matrices seems plausible, try to find the matrices. There are a lot of degrees of freedom, so let's erase some of them and fashion arbitrarily a row-rank 2 matrix for $W$ and then use that to fill out $D$. This isn't sketchy because we leave ourselves four variables in $D$, which will result in four equations in $4$ variables so long as $W$ has independent rows.
So, let
$$
W =
\begin{bmatrix}
1 & 1 & 1 \\
1 & 0 & 1
\end{bmatrix}
$$
Now to fill out $D$ you can just write
$$D =
\begin{bmatrix}
2 & 2 \\
a & b \\
c & d
\end{bmatrix}
$$
and solve the resulting system of linear equations. The system will be solvable!