Yes, the first move you made does preserve equivalence, and here are some basic rules for pulling a quantifier outside logical operators, where P does not contain any free variables x:
$P \lor \forall x \: \phi(x) \equiv \forall x (P \lor \phi(x))$
$P \lor \exists x \: \phi(x) \equiv \exists x (P \lor \phi(x))$
$P \land \forall x \: \phi(x) \equiv \forall x (P \land \phi(x))$
$P \land \exists x \: \phi(x) \equiv \exists x (P \land \phi(x))$
$P \rightarrow \forall x \: \phi(x) \equiv \forall x (P \rightarrow \phi(x))$
$P \rightarrow \exists x \: \phi(x) \equiv \exists x (P \rightarrow \phi(x))$
$\forall x \: \phi(x) \rightarrow P \equiv \exists x (\phi(x) \rightarrow P)$
$\exists x \: \phi(x) \rightarrow P \equiv \forall x (\phi(x) \rightarrow P)$
So take care of those last two: the quantifier changes if you pull it outside a conditional, and it is the antecedent of that conditional!
And because of the latter, there is no simple equivalence involving puling a quantifier outside a biconditional.
Also, you can move a universal over another universal (and same for existentials), but you can't move a universal over an existential or vice versa. That is:
$\forall x \forall y P(x,y) \equiv \forall y \forall x P(x,y)$
and
$\exists x \exists y P(x,y) \equiv \exists y \exists x P(x,y)$
But not:
$\forall x \exists y P(x,y) \equiv \exists y \forall x P(x,y)$
It's because, as they say, if there is an object in the domain that is not a student, then $S(x)$ would be false, and given the way that we have defined the truth-functional implication, the $S(x) \rightarrow M(x)$ part would then be automatically true. Hence, the statement $\exists x (S(x) \rightarrow M(x))$ can be made true by simply some object in the domain that is not a student. In fact, if there isn’t a single student in the domain, the statement is automatically true! This is of course not what we want. We do want to say that there is a student, and that they visited Mexico, i.e. $\exists x (S(x) \land M(x))$
For the universal, things are different. If we were to use $\forall x (S(x) \land M(x))$, then we are saying that everything in the domain is a student and went to Mexico ... so if we would have objects in the doamin other than student, e.g. bananas, then we end up pointing to those bananas and say: "that is a student, and it visited Mexico" ... which is clearly not what we want ... We are merely saying that all students visited Mexico, not that everything visited Mexico. That is, we should say that out of all objects: if it is a student, then 'it' went to Mexico ... i.e. $\forall x (S(x) \rightarrow M(x))$
Best Answer
The mere presence of a universal or existential quantifier is irrelevant. The only relevant thing is whether the statement’s outermost logical operator is a quantifier.
Any sentence of the form $\forall x \phi$ where $FV(\phi) \subseteq \{x\}$ is true in the empty model, and the corresponding sentence $\exists x \phi$ is false in the empty model. This follows from the definition of $\models$.
Note that in general, when we’re deciding the truth of some proposition $\phi$ in a model $M$, we consider the statement $M, u \models \phi$, where $u : D \to M$, $D$ is a finite set of variables, and $FV(\phi) \subseteq D$. In the case of the empty model, the only such $u$ will always be the trivial empty $u$ where $D = \emptyset$.