First consider the case when $M_g$ is the stack:

Over $\mathbb C$ this is a consequence of the Torelli theorem: A map from a rational or elliptic curve to $M_g$ is the same as a smooth family over that curve. Then considering the period map gives a map from the same curve to the parameter space of Hodge structures. However, that is hyperbolic, so any holomorphic map from $\mathbb C$ is trivial. Therefore the Hodge structures of the fibers are the same, but then Torelli says that then the curves are also the same, so the map to moduli is trivial. (In fact this proof shows that even a rational curve minus $2$ points cannot map there either).

Actually, a lot more is true:
The same statement holds if we replace $M_g$ with $M_h$, the moduli stack of canonically polarized smooth projective varieties with Hilbert polynomial $h$. (For $\deg h=1$ you get back the corresponding $M_g$). Torelli is no longer true, but the desired statement is: There are no non-trivial maps from an elliptic curve or a rational curve minus $2$ points. This is proved in *Algebraic hyperbolicity of fine moduli spaces* J. Algebraic Geom. 9 (2000), no. 1, 165–174.

Then one may wonder if something could be said for higher dimensional bases. The direct generalization of the original question would be to replace an elliptic curve with an abelian variety. The same statement holds, (in fact a little more than that is) proved in
*Families over a base with a birationally nef tangent bundle*
Mathematische Annalen, 1997, Volume 308, Number 2, Pages 347-359

If one wants to generalize further, that is, to include the case of rational curves minus two points, one possibility is

**Viehweg's conjecture** (roughly stated)

Any quasi-projective variety that admits a generically finite morphism to $M_h$ is of log general type.

Here *log general type* means that if $X$ is the variety in question and $\overline X$ is a projective variety such that $X\subseteq \overline X$ is an open subset and $D=\overline X\setminus X$ is a divisor, then $\omega_{\overline X}(D)$ is big (=has maximal Kodaira dimension).

If you have not seen this before, check that curves of log general type are:
Any open subset of a curve of genus at least $2$, any proper open subset of an elliptic curve, and any open subset of a rational curve missing at least $3$ points. In other words, the only non-log general type curves are the (projective) elliptic curves and rational curves missing at most $2$ points. In other words, Viehweg's conjecture for $M_g$ is just the first statement above.

Viehweg's conjecture is currently known for proper base varieties by *Families of varieties of general type over compact bases*, Advances in Mathematics, Volume 218, Issue 3, 20 June 2008, Pages 649–652 and *Viehwegʼs hyperbolicity conjecture is true over compact bases*, Advances in Mathematics, Volume 229, Issue 3, 15 February 2012, Pages 1640–1642 and over (up to) $3$-dimensional bases in general by *The structure of surfaces and threefolds mapping to the moduli stack of canonically polarized varieties*, Duke Math. J. Volume 155, Number 1 (2010), 1-33..

As far as the coarse space goes, it is probably more of a curiosity, but it still seems interesting. Oort proved that the coarse space of $M_g$ actually contains rational curves. Perhaps his proof can be adapted to prove the same for an elliptic curve. (The main idea is to construct a family over a curve with a given map to $\mathbb P^1$ such that fibers over the points mapping to the same point on $\mathbb P^1$ are isomorphic, so the moduli map factors through the map to $\mathbb P^1$).

And then there are many results concerning the question of what kind of complete subvarieties might $M_g$ have. Or what about complete subvarieties through a general point? There are various results in this direction, but I am already digressing....

*Remark* all of the above holds over an algebraically closed field of characteristic $0$. In characteristic $p$ all kinds of weird things happen, so I would expect that probably most of this fails.