From what I understand:
$D > 0$ and a perfect square $\Longrightarrow$ Real and Rational Roots
$D > 0$ but not a perfect square $\Longrightarrow$ Real and Irrational Roots
$D = 0$ $\Longrightarrow$ Double Root
$D < 0$ $\Longrightarrow$ Complex Roots
My question is that the discriminant of $\sqrt{3}x^2-4\sqrt{3}$ $\Longrightarrow$ 48
48 is not a perfect square yet the roots for $\sqrt{3}x^2-4\sqrt{3}=0$ are real and rational.
"My teacher just said the rule is if the discriminant is a perfect square then the roots are real and rational"
That rule is for polynomials with rational coefficients.