Denote by $\mathbb{P}_{n}$ be the set of positive definite $n \times n$ matrices. In $\mathbb{P}_{n},$ we define an partial order as follow: for $X, Y \in \mathbb{P}_{n},$ we say $X<Y$ if $Y-X$ is also a positive definite matrix. Let $\lambda=2^{1-1 / p}$ with $p>1$ be a real number.
Question: For $0<X<Y<\lambda X,$ do there exist positive definite matrices $A, B$ such that
$$
X=\frac{A+B}{2}, \quad Y=\left(\frac{A^{p}+B^{p}}{2}\right)^{1 / p} ?
$$
Remark: The answer in the case of a scalar is Yes, and $\lambda=2^{1-1 / p}$ comes from this case to ensure that the function
$$
f(a)=\left(\frac{a^{p}+(2 x-a)^{p}}{2}\right)^{1 / p}
$$
is surjective from $[0,2 x]$ to $[x, \lambda x]$
No. A positive answer to your question for $p=2$ would in particular imply that
$$
0<X<Y<\lambda X \Longrightarrow X^{2} \leq Y^{2}
$$
which is well-know to be false (the square map is not operator monotone), see below for an expl counterexample.
Indeed, if
$$
X=\frac{A+B}{2}, \quad Y=\left(\frac{A^{2}+B^{2}}{2}\right)^{1 / 2}
$$
then we have $Y^{2}-X^{2}=\frac{(A-B)^{2}}{4}$.
For a concrete counterexample, take $X=\left(\begin{array}{cc}1 & 0 \\ 0 & \frac{1}{4}\end{array}\right)$ and $Y=X+t\left(\begin{array}{cc}1 & 1 \\ 1 & 1\end{array}\right)$ for small $t$.
Then $Y^{2}-X^{2}$ has determinant $-(3 t / 4)^{2}$ so is not positive.