Let us make some constructions, that are useful for both directions.
We relax the condition on $ABCDA'B'C'D'$ to be a cube, it is enough to work with a "box", a cuboid, i.e. a rectangular parallelipiped. (All faces are rectangles.)
To have an ad-hoc quick manner to work with the faces, we name them up ($A'B'C'D'$) and down ($ABCD$), left ($ADD'A'$) and right ($BCC'B'$).
Let us draw the segments $PP_1$ and $QQ_1$ parallel and equal to the segments $AB\|DC\|D'C'\|A'B'$, and thus also to the up and down planes,
so that $P_1\in BC'$ and $Q_1\in DA'$.
They are perpendicular on the left and right planes.
So $PP_1Q_1Q$ is a rectangle.

We may need also $R=BC'\cap CB'$ and $S=AD'\cap DA'$, the centers of symmetry of the right and left faces. Let $T$ also be the mid point of $RS$, and $OO'$, it is the center of symmetry of the "box".
It turns out that from the whole box we only need the (right) prism
$$
SADRBC\ .
$$
Its parallel faces $\Delta SAD$ and $\Delta RBC$ are isosceles triangles,
$SA=SD$ and $RB=RC$.
The point $M$ is the mid point of the diagonals of the rectangle $PP_1QQ_1$,
and their intersection. An other way to introduce it is as the mid point of the segment delimited by the mid points $K, L$ of $PQ_1$, and respectively $P_1Q$.
It is time to extract the simpler equivalent problem for the prism, and give the proof.
Let $SADRBC$ be a right prism with parallel triangular faces $\Delta SAD$, $\Delta RBC$, which are isosceles in $R,S$. Let $P,P_1,Q,Q_1$ be points on the lines $SA,RB,RC,SD$ so that the segments $PP_1,QQ_1$ are parallel and equal to the segments (sides of the prism) $SR, AB,DC$. Let $T$ be the mid point of $RS$. Let $O=AC\cap BD$ be the center of the rectangle $ABCD$.
Let $K,L$ be the mid points of $PQ_1,P_1Q$. Let $M$ be the mid point of $KL$, it is also the intersection of the diagonals of the rectangle $PP_1QQ_1$, and its center of symmetry.
Then the $PQ$ (and/or plane of the rectangle $PP_1QQ_1$) is parallel to $ABCD$ if and only if $M$ is on $TO$.

Let us start the proof.
(The curios, ambitious reader may want to search for a proof on her, his own. The used construction of supplementary points below is not shown in this picture.)
$(1)$ Assume that $PQ$ is parallel to $(ABCD)$, i.e.
$PP_1QQ_1\|ABCD$. The $PQ_1\|AD$, $P_1Q\|BC$, so the triangles $\Delta SPQ_1$,
$\Delta RP_1Q$ are isosceles (being similar to the corresponding faces of the prism). So $SK, RL$ are not only medians in these triangles, but also heights.
SO $SK,RL$ are perpendicular also on $AD,BC$, intersect them in their mid points, $K',L'$ say, and the segment $K'L'$ joining them passes through $O$, its mid point. So $T,M,O$ are collinear, being the mid points of the segments (parallel and equal segments) $SR,KL,K'L'$.
We conclude $M\in TO$.
$\square$
$(2)$ Assume that $M$ is on $TO$.
The plane $SRLK$ determined by the parallel and equal segments $SR\|KL$
thus passes through $O$, so it intersects $ABCD$ in the line through $O$ parallel to $SR$, which is $K'L'$ with $K',L'$ the mid points of $AD,BC$.
The points $S,K,K'$ are thus in the intersection of the planes $SAD$ and $SRKLK'L'$, so they are collinear. So $K$ is not only on the median from $S$ in $\Delta SPQ_1$, but also on its angle bisector ($AK'$ of $\widehat {ASD}=\widehat{PSQ_1}$). So $\Delta SPQ_1$ is isosceles, giving $PQ_1\|AD$, so the plane $PP_1QQ_1$ is parallel to $ABCD$.
$\square$