Let $D$ be the spacetime dimension. The action is dimensionless for any $D$ (since the action has units of $\hbar$, and we set $\hbar=1$)., Since $S = \int {\rm d}^D x \mathcal{L}$, and the volume element ${\rm d}^D x$ has mass dimension $-D$, this means the Lagrangian $\mathcal{L}$ has dimension $D$
Assuming we have a weakly coupled scalar field theory, the scaling dimension of the field $\phi$ will be determined by the kinetic term, $\mathcal{L} \sim (\partial \phi)^2$ (if you like, in the free theory only the kinetic term and maybe mass term are there, so in the free theory these determine the scaling of the field, and then perturbative quantum corrections will only lead to small changes to the free theory mass dimension). Since derivatives have mass dimension $1$ in any dimension, and the Lagrangian has mass dimension $D$, in order for things to work, the field must have dimensions $(D-2)/2$. You can check that in $D=4$, this works out to say that the field should have dimension $1$, which is the case.
Then we can consider a general operator (term in the Lagrangian) of the form
\begin{equation}
\mathcal{L} \sim \lambda \partial^{n_d} \phi^{n_\phi}
\end{equation}
where $\lambda$ is a (possibly dimensionful) coupling constant; $n_d$ is the number of derivatives; and $n_\phi$ is the number of powers of $\phi$. Then the dimension of $\lambda$ is
\begin{equation}
\Delta_\lambda = D - n_d - n_\phi \frac{D-2}{2} = D + \left(1-\frac{D}{2}\right)n_\phi - n_d
\end{equation}
For $D=4, n_\phi=4, n_d=0$, this yields $\Delta_\lambda=0$, as you expect.
For an arbitrary $D$, with $n_\phi=4, n_d=0$, we have
\begin{equation}
\Delta_\lambda = 4 - D
\end{equation}
which is negative for all $D>4$; in other words, $\phi^4$ theory is power-counting non-renormalizable for all $D>4$.
Since we set up the formalism, we might as well look at a general interaction. Let's set $n_d=0$. Then the expression is
\begin{equation}
\Delta_\lambda = D + \left(1-\frac{D}{2}\right)n_\phi
\end{equation}
Then...
- For $D=1$, this is always positive.
- For $D=2$, the mass dimension is always $2$ for any operator. (2 dimensions is special in many ways).
- For $D=3$, this simplifies to $\Delta_\lambda = 3 - \frac{n_\phi}{2}$, which is only nonegative if $n_\phi \leq 6$. Therefore, $\phi^6$ theory is dimensionless in three dimensions. Higher powers of $\phi$ are nonrenormalizable.
- For $D=4$, this becomes $\Delta_\lambda = 4 - n_\phi$, so only $\phi^3$ and $\phi^4$ theories are renormalizable.
- For $D=5$, this becomes $\Delta_\lambda = 5 - \frac{3 n_\phi}{2}$, so only $\phi^3$ is renormalizable.
- For $D=6$, we have $\Delta_\lambda = 6 - 2 n_\phi$, so $\phi^3$ is dimensionless (and therefore analogous to $\phi^4$ theory in $4$ dimensions). This is the theory that Srednicki bases the first third of his textbook on.
- For $D \geq 7$, all terms with $n_\phi \geq 3$ have negative mass dimension, and so are not renormalizable.
Since $n_d$ contributes negatively to $\Delta_\lambda$, any interactions with derivatives can only possibly be renormalizable if the derivative-less version is.
Typically, when you want to require a symmetry you choose to restrict the allowed terms in your Lagrangian to a smaller subset, this subset being the terms that are singlets under the symmetry group. For example, consider the Lagrangian of two fields $\phi_1$ and $\phi_2$. If it depends only on the combinations
$$
\phi_1^2+\phi_2^2\,,\quad(\partial\phi_1)^2+(\partial\phi_2)^2\,,
$$
then there is an $\mathrm{SO}(2)$ symmetry. This statement amounts to saying that terms such as $\phi^2_1$ or $\phi_1\phi_2$ are absent.
Now suppose that you write down all terms that involve the particles you are considering and which are relevant. Relevant here is meant in an RG sense, namely terms that survive in the infra-red. If all these terms happen to be singlets of a certain group, then so be it, your Lagrangian is going to have that symmetry. But it was not a deliberate choice, it's just what is forced upon you when you go to low energies.
Because of this fact such symmetries are called "accidental."
An example of this is QED which is $\mathsf{P}$ invariant but just because you can't write any $\mathsf{P}$-breaking term that has dimension below four which is made only of electrons and photons.
Best Answer
The key thing is that you need to be working with canonically normalized fields in order to use the power counting arguments.
Let's expand GR around flat space \begin{equation} g_{\mu\nu} = \eta_{\mu\nu} + \tilde{h}_{\mu\nu} \end{equation} The reason for the tilde will become clear in a second. So long as $\tilde{h}$ is "small" (or more precisely so long as the curvature $R\sim (\partial^2 \tilde{h})$ is "small"), we can view GR as an effective field theory of a massless spin two particle living on flat Minkowski space.
Then the Einstein Hilbert action takes the schematic form \begin{equation} S_{EH}=\frac{M_{pl}^2}{2}\int d^4x \sqrt{-g} R = \frac{M_{pl}^2}{2} \int d^4x \ (\partial \tilde{h})^2 + (\partial \tilde{h})^2\tilde{h}+\cdots \end{equation} where $M_{pl}\sim 1/\sqrt{G}$ in units with $\hbar=c=1$. $M_{pl}$ has units of mass. In this form you might thing that the interaction $(\partial \tilde{h})^2 \tilde{h}$ comes with a scale $M^2_{pl}$ with a positive power. However this is too fast--all the QFT arguments you have seen have assumed that the kinetic term had a coefficient of -1/2, not $M_{pl}^2$. Relatedly, given that $M_{pl}$ has units of mass and the action has units of $(mass)^4$, the field $\tilde{h}$ is dimensionless, so it is clearly not normalized the same way as the standard field used in QFT textbooks.
Now classically, the action is only defined up to an overall constant, so we are free to think of $M_{pl}^2$ as being an arbitrary constant. However, in QFT, the action appears in the path integral $Z=\int D\tilde{h}e^{iS[\tilde{h}]/\hbar}$ (note the notational distinction between $\tilde{h}$ and $\hbar$). Thus the overall constant of the action is not a free parameter in QFT, it is fixed and has physical meaning. Alternatively, you have to remember that the Einstein Hilbert action will ultimately be coupled to matter; when we do that, the scale $M_{pl}$ sitting in front of $S_{EH}$ will not multiply the matter action, and so $M_{pl}$ sets the relative scale between the gravitational action and the matter action.
The punchline is that we can't simply ignore the overall scale $M_{pl}^2$, it has physical meaning (ie, we can't absorb $M_{pl}$ into an overall coefficient multiplying the action). On the other hand, we want to put the action into a "standard" form where the overall scale isn't there, so we can apply the normal intuition about power counting. The solution is to work with a "canononically normalized field" $h$, related to $\tilde{h}$ by
\begin{equation} \tilde{h}_{\mu\nu} = \frac{h_{\mu\nu}}{M_{pl}} \end{equation}
Then the Einstein Hilbert action takes the form
\begin{equation} S_{EH} = \int d^4 x \ (\partial h)^2 + \frac{1}{M_{pl}} (\partial h)^2 h + \cdots \end{equation}
In this form it is clear that the interactions of the form $(\partial h)^2 h$ have a "coupling constant" $1/M_{pl}$ with dimensions 1/mass, which is non-renormalizable by power counting in the usual way.