I came across this in my text book-
The negation of a statement of the form "$\exists x \in D$ such that $Q(x)$" is logically equivalent to a statement of the form "$\forall x \in D$ such that $\neg Q(x)$".
Symbolically, $\neg\big(\exists x\in D:Q(x)\big) ~\equiv~ \big(\forall x \in D:\neg Q(x)\big)$.
Negations are defined for statements. Thus applying it on a propositional function is undefined as a propositional function is not a statement. Here it shouldn't have been applied on $Q(x)$.
I have gone through Rosen's book and Wikipedia but they do not justify the usage of negation in this context, what am I missing? I think the authors do not technically mean negation but that they mean something like the negation.
You are not correct that negation applies only to statements (well-formed formulas without free variables). In fact, negation, like conjunction and disjunction, apply to any well-formed formulas, and any $n$-ary predicate symbol applied to $n$ variable letters or constant symbols is a well-formed formula.
In other words: $Q(x)$ is a well-formed formula; therefore $\lnot Q(x)$ is, too.
All this is explained on Wikipedia.