As mentioned in the update in the question, I'll assume that the given ellipse has the form
$\dfrac{x^2}{a^2} + \dfrac{y^2}{b^2} = 1 \tag{1}$
where $a \gt b$.
We know that the cone with such a section must have its apex in the $xz$ plane, so let the apex be at $A = (x_1, 0, z_1)$. Also, we know that the rotation matrix associated with the cone must a rotation matrix about the $y$-axis. Let the angle of rotation be $\theta_1$. Then
$ R = \begin{bmatrix} \cos \theta_1 && 0 && \sin \theta_1 \\ 0 && 1 && 0 \\
-\sin \theta_1 && 0 && \cos \theta_1 \end{bmatrix}\tag{2}$
In addition, the unrotated upright cone matrix takes the form
$ D_c = \begin{bmatrix} \cos^2 \phi && 0 && 0 \\ 0 && \cos^2 \phi && 0 \\
0 && 0 && \cos^2 \phi - 1 \end{bmatrix} \tag{3} $
And the equation of the cone is
$ (r - A)^T Q_c (r - A) = 0 \tag{4}$
where $ r = [x,y,z]^T $, and $Q_c = R D_c R^T $
Calculating $Q_c = R D_c R^T $, we get,
$Q_c = \begin{bmatrix} \cos^2 \phi - \sin^2 \theta_1 && 0 && - \sin \theta_1 \cos \theta_1 \\ 0 && \cos^2 \phi && 0 \\ - \sin \theta_1 \cos \theta_1
&& 0 && \cos^2 \phi - \cos^2 \theta_1 \end{bmatrix} \tag{5}$
Setting $r = [x, y, 0]$, will give the intersection of the cone with the $xy$ plane. For brevity, let $C = \cos \phi, s_1 = \sin \theta_1, c_1 = \cos \theta_1$. Then the equation of the intersection is
$( C^2 - s_1^2 ) (x - x_1)^2 + C^2 y^2 + (C^2 - c_1^2 ) (z_1)^2 - 2 s_1 c_1 (x - x_1)(-z_1) = 0 \tag{6}$
And this is a scalar multiple of the above given equation of the ellipse.
Equating coefficients,
$ - 2 x_1 (C^2 - s_1^2) + 2 z_1 s_1 c_1 = 0 \tag{7} $
$ C^2 - s_1^2 = \dfrac{k}{a^2} \tag{8} $
$C^2 = \dfrac{k}{b^2} \tag{9} $
$x_1^2 (C^2 - s_1^2) + z_1^2 (C^2 - c_1^2) - 2 z_1 x_1 s_1 c_1 = -k \tag{10} $
Substitute for $k$ from $(8)$ into $(9)$ and $(10)$, thus eliminating $k$.
$ - x_1 (C^2 - s_1^2) +z_1 s_1 c_1 = 0 \tag{11} $
$ C^2 b^2 = a^2 (C^2 - s_1^2) \tag{12}$
$ x_1^2 (C^2 - s_1^2) + z_1^2 (C^2 - c_1^2) - 2 z_1 x_1 s_1 c_1 = - a^2 (C^2 - s_1^2) \tag{13}$
with the aid of $(11)$ and $(12)$, equation $(13)$ becomes
$ - x_1^2 (C^2 - s_1^2) + z_1^2 (C^2 - c_1^2) = -a^2 (C^2 - s_1^2) = -b^2 C^2 $
hence,
$ \dfrac{x_1^2}{a^2} - \dfrac{ z_1^2 (C^2 - c_1^2) }{ b^2 C^2 } = 1 \tag{14}$
Now, note that $(C^2 - s_1^2) / C^2 = b^2 / a^2 $. Therefore,
$s_1^2 = C^2 e^2 $
where $e$ is the eccentricity of the given ellipse, $e = \sqrt{1 - \dfrac{b^2}{a^2}} $. Hence,
$c_1^2 = 1 - C^2 e^2 $
Then,
$C^2 - c_1^2 = C^2 (1 + e^2) - 1 $
Substituting this into $(14)$,
$\dfrac{ x_1^2}{a^2 } - z_1^2 \dfrac{ C^2 (1 + e^2) - 1 }{ b^2 C^2 } = 1 \tag{15} $
i.e.
$ \dfrac{x_1^2}{a^2} - z_1^2 \left( \dfrac{1 + e^2}{b^2} - \dfrac{1}{b^2 C^2} \right) = 1 \tag{16}$
Now, from $(11)$ we have
$ x_1^2 (C^2 - s_1^2)^2 = z_1^2 s_1^2 c_1^2 $
but, $s_1^2 = C^2 e^2 $, and $c_1^2 = 1 - C^2 e^2 $
Therefore,
$ x_1^2 C^4 (1 - e^2)^2 = z_1^2 C^2 e^2 (1 - C^2 e^2 ) $
and this leads to
$ C^2 b^2 = \dfrac{b^2 z_1^2 e^2}{ (x1^2 (1 - e^2)^2 + e^4 z1^2 )} $
Substituting this into $(16)$
$ \dfrac{x_1^2}{a^2} - z_1^2 \left( \dfrac{(1 + e^2)}{b^2} + \dfrac{( x_1^2 (1 - e^2)^2 + e^4 z_1^2 )}{b^2 e^2} \right) = 1 \tag{17}$
From which,
$ x_1^2 \left( \dfrac{1}{a^2} + \dfrac{(1 - e^2)^2}{b^2 e^2} \right) - z_1^2 \left( \dfrac{1 + e^2}{b^2} - \dfrac{e^2}{b^2} \right) = 1 \tag{18} $
Re-arranging,
$ x_1^2 \left( \dfrac{b^2 e^2 + a^2 (1 - e^2)^2 }{a^2 b^2 e^2} \right) - \dfrac{z_1^2}{ b^2 } = 1 \tag{19}$
Now $ b^2 e^2 + a^2 (1 - e^2)^2 = b^2 e^2 + a^2 (1 - e^2)\left (\dfrac{b^2}{a^2} )\right) = b^2 (e^2 + 1 - e^2) = b^2 $
Therefore, from this and $(19)$,
$ \dfrac{x_1^2}{a^2 e^2} - \dfrac{z_1^2}{b^2} = 1$
But $a^2 e^2 = a^2 - b^2 $, hence the final equation is
$ \dfrac{x_1^2}{a^2 - b^2} - \dfrac{z_1^2}{b^2} = 1 \tag{20} $
This equation is mentioned here in an answer by intelligenti pauca to a similar question.
So to build such a cone, start by selecting $x_1, z_1$ a point on the hyperbola $(20)$, then compute the cosine of the semi-vertical angle $\phi$, from
$ C^2 = \dfrac{ z_1^2 e^2}{x_1^2 (1 - e^2)^2 + e^4 z_1^2} $
As derived above. Next compute $s_1, c_1$ from
$s_1 = \pm C e$
$c_1 = \pm \sqrt{1 - s_1^2} $
Now the cone is specified (there are four of them) is specified by equations $(4)$ and $(5)$.