For a quaternion algebra $D$, introduce the quaternionic similitude unitary groups:
\begin{equation}
\mathrm{GU}\_D = \left\{ g \in \mathrm{GL}(D) \ : \ g^\star 
\left(
\begin{array}{cc}
& 1 \\
1 &
\end{array}
\right)
g = \mu(g) 
\left(
\begin{array}{cc}
& 1 \\
1 &
\end{array}
\right), \mu(g) \in \mathbf{G}\_m
 \right\}
\end{equation}


The $\mathrm{GU}\_D $ are the inner forms of $\mathrm{GSp(4)}$ when $D$ describes the quaternion algebras. For almost every places $v$ of $F$, more precisely the split ones, this group is $G\_v \simeq \mathrm{GSp(4,F\_v)}$. 



> 
> When are those $\mathrm{GU}\_D$ of compact automorphic quotient?
> 
> 
> 


I believe assuming $D$ to be totally definite at infinity (i.e.ramified at archimedean places) is enough, but is it necessary?



Automorphic quotients for inner forms or $GSp(4)$
Let me give you the inner forms of $\mathrm{GSp}(4)$ with compact adelic quotient.


Every nonsplit inner form of $\mathrm{GSp}(4)$ is obtained in the following way: take $D$ a division quaternion algebra over $F$, let $V$ be a $D$-Hermitian space of $D$-dimension $2$, and construct $G = \mathrm{GU}(V)$.


By a theorem of Borel and Harish-Chandra, the adelic quotient of $G$ is compact if and only if $G$ modulo its center is anisotropic (in the algebraic group sense: it contains no nontrivial split torus).


This turns out to be equivalent to $V$ being anisotropic (in the quadratic/hermitian form sense: it has no nonzero isotropic vector). Over a number field, by the local-global principle for quadratic forms we can test anisotropy locally: over $p$-adic places, $V$ has $8$ variables as a quadratic form and is therefore isotropic, and over real places, $V$ is anisotropic if and only if it is positive definite or negative definite.


In summary, $G = \mathrm{GU}(V)$ has compact adelic quotient if and only if $F$ admits a real place at which $D$ is definite and $V$ is positive definite or negative definite.


For instance, the $D$-Hermitian form $x\bar{x}+y\bar{y}$ works over a totally definite quaternion algebra, but the one you wrote down is $x\bar{y}+y\bar{x}$.


