maximize $\det(I+\Lambda Q\Lambda)$, where $Q$ is p.s.d. with $\mathrm{rank}(Q)\le 2$ and $\mathrm{tr}(Q)\le 2$ Suppose $\Lambda=\left[ \begin{array}{ccc} 4 & 0 & 0 \\ 0 & 2 & 0 \\ 0 & 0 & 1 \end{array}\right]$ is diagonal, and $Q$ is a 3-by-3 positive semi-definite (psd) matrix, with $\mathrm{rank}(Q)\le 2$ and $\mathrm{tr}(Q)\le 2$.  How should we choose $Q$ to maximize $\det(I+\Lambda Q\Lambda)$?
Without the rank constraint, the answer is simply a diagonal $Q$, with the diagonal elements being $Q_{ii}=\mu-\frac{1}{\Lambda_{ii}^2}$, where $\mu$ is determined by $\mathrm{tr}(Q)=2,$ i.e. $\mu=1\frac{5}{48}.$  This can be proved using the Hadamard's inequality, i.e. $\det(I+\Lambda Q\Lambda)\le \underset{i}\Pi (1+\Lambda_{ii}^2Q_{ii}),$ and maximizing the RHS with Lagrange multipliers.  (This is essentially the "beamforming" problem in wireless communication.)
However, when we constrain the rank of $Q$ to be 2 or less, the answer is not so clear to me.  Is the optimal $Q$ still diagonal (with $Q_{33}=0$)?
 A: 1st argument. I removed my first attempt to show this using the Hadarmard's Inequality. As user8675309 pointed out in the comments below, we cannot conclude that $Q$ is still diagonal with $Q_{3,3} = 0$ from Hadarmard's Determinant Inequality.
2nd argument. Denote $X = I + \Lambda Q \Lambda$ and consider the problem of maximizing the determinant of $X$.
The off-diagonal entries of $X$ should be equal to 0 as a necessary condition since they decrease the objective value. Implying that optimal $Q$ is diagonal matrix.
To satisfy $\text{rank}(Q) \leq 2$, at least one diagonal entry of $Q$ should be $0$. Since determinant of $X$ is a monotone increasing function in its diagonal entries. And, by looking at the values in $\Lambda = \text{diag}([4, 2, 1])$, the maximum is achieved at $Q_{3, 3} = 0$.
All in all, the optimal $Q$ is the solution of the relaxed problem where $\text{rank}(Q)$ is replaced by constraint $Q_{3,3} = 0$.
Solution. Instead of maximizing the determinant of $X$, we can maximize the SDP representable concave function log determinant of $X$ and rewrite the problem as:
\begin{align*}
& \text{maximize} \ \text{log} \ \text{det}\left(I + \Lambda Q \Lambda\right) \\
& \text{subject to:} \\
& \qquad \text{trace}(Q) \leq 2 \\
& \qquad Q_{3,3} = 0 \\
& \qquad \, Q \succeq 0
\end{align*}
I got the same result as @RiverLi by solving the corresponding relaxation with added constraint $Q_{3,3} = 0$, here is the code, using CVXPY in Python:
import numpy as np
import cvxpy as cp

I = np.identity(3)
L = np.diag(np.array([4, 2, 1]))
Q = cp.Variable((3, 3), symmetric=True)

objective = cp.log_det(I + L @ Q @ L)
constraints = [cp.trace(Q) <= 2]
constraints += [Q[2, 2] == 0]
constraints += [Q >> 0]
prob = cp.Problem(cp.Maximize(objective), constraints)
prob.solve()
Q = np.round(Q.value, 2)

print('rank(Q) = %.2f' % np.linalg.matrix_rank(Q))
print('objective(Q) = %.2f' % np.linalg.det(I + L @ Q @ L))
print('trace(Q) = %.2f' % np.trace(Q))
print('Q = '); Q

Gives:
rank(Q) = 2.00
objective(Q) = 85.56
trace(Q) = 2.00
Q =
array([[1.09, 0.  , 0.],
       [0.  , 0.91, 0.],
       [0.  , 0.  , 0.]])

A: OP's conjecture is right; here's a proof using majorization and interlacing.
To start, it's better to write this as optimizing the equivalent problem of
$\det\big(D +Q'\big)$
where $d_{1,1}=1$, $d_{2,2} = \frac{1}{4}$ and $d_{3,3}=\frac{1}{16}$
here $D$ is diagonal and observes a convention I enforce throughout this post-- eigenvalues are always numbered in descending order-- so
$d_{3,3}\leq d_{2,2}\leq d_{1,1}$
now consider an initial constrained optimization with
$\text{rank}(Q')\in \big\{1,2\big\}$ and $\text{trace}(Q')=2$
then at the end we consider the case of $\text{trace}(Q') \in [0,2)$
Now $\big(D +Q'\big)$ is a diagonal matrix $D$ plus (at most) 2 rank one symmetric PSD matrices (i.e. at most 2 rank one updates).  Applying interlacing on the eigenvalues after the first update gives
$d_{3,3}\leq \lambda_{3}\leq d_{2,2}\leq \lambda_{2}\leq d_{1,1}\leq \lambda_{1}$
and after the 2nd rank one (or possibly zero) update
$\lambda_{3}\leq \sigma_{3} \leq \lambda_{2}\leq \sigma_{2}\leq \lambda_{1}\leq \sigma_{1}$
$\implies \sigma_3\leq d_{1,1}$
Thus a qualifying matrix with eigenvalues $\sigma_1=\sigma_2$ and $\sigma_3=d_{1,1}$ has its eigenvalues majorized by all other possibilities for $\big(D +Q'\big)$ . I.e. working backwards, compare this with an arbitrary possibility of eigenvalues
$\sigma_1+\sigma_2 + \sigma_3 = \sigma_1'+\sigma_2' + \sigma_3'$ (since traces are equal)    and
$\sigma_1+\sigma_2=\sigma_1+\sigma_2 +(\sigma_3-d_{3,3})= \sigma_1'+\sigma_2' + (\sigma_3' -d_{3,3}) \leq \sigma_1'+\sigma_2'$
and since $\sigma_1'\geq \sigma_2'$ by definition,
$\implies \sigma_1' \geq \frac{1}{2}\big(\sigma_1'+\sigma_2'\big)\geq \frac{1}{2}\big(\sigma_1+\sigma_2\big)=\sigma_1$
which proves the majorization.
Since the nth elementary symmetric polynomial ($n=3$ here) is Schur Concave, this proves
$\sigma_1\cdot\sigma_2\cdot \sigma_3=\det\big(\Sigma)= \det\big(D +Q'\big)$ is maximal and in particular we select this with diagonal $Q'$ having components $0$ and $\frac{29}{32}$ and $\frac{35}{32}$ (I changed the ordering from $Q$ to $Q'$ but there are only $3!=6$ possibilities so the intended result should be obvious.)

Finally note that the above interlacing argument implies that $\text{trace}\big(Q'\big)\lt 2$ is dominated, i.e. for $\delta \in [0,1)$
$\det\Big(\big(D+\delta Q'\big)\Big)\lt \det\Big(\big(D+\delta Q'\big)+(1-\delta)Q' \Big)=\det\Big(D+Q'\Big)$
since the $k$th eigenvalue of $\Big(\big(D+\delta Q'\big)+(1-\delta)Q'\Big) $ is at least as big as the $k$th eigenvalue of  $\big(D+\delta Q'\big)$ (all of which are positive and the trace is strictly larger so at least one eigenvalue is strictly bigger.  Note: $\delta :=0$ implicitly  accommodates the rank zero case.)
