Then the integral becomes localized on the field configurations for which the fermionic variables are invariant under the supersymmetry.
This is not so trivial as to explain why. You need to go through various steps in order to understand localization. Let me give you a brief guide:
I will give the example of $\mathcal{N}=2$ susy gauge theory in $d=4$ with gauge group $SU(N)$. In the literature you can find other examples but I am not as well informed on them so maybe another PO user can help with that. So, our theory has extended susy with generators
$$Q_{\alpha}^I, \,\,\,\,\,\,\,\,\bar{Q}_{\dot{\beta}I},$$
where $\alpha,\beta=1,2$ and $I=1,2$ so in total we have 8 supercharges. the spectrum of the theory is a) a hypermultiplet with two scalars (Higgs) $\phi, \bar{\phi}$ and a gluon $A_{m}$ in the bosonic sector and two chiral gluinos $\lambda_{\alpha}^I, \lambda_{\dot{\alpha}}^I$ in the fermionic sector and b) a chiral multiplet with a squark $q^{I}$ in the bosonic sector and two chiral quarks $\psi_{\alpha}, \bar{\psi}_{\dot{\alpha}}$ in the fermionic sector. The Lagrangian can be summarized as
$$ \mathcal{L} = \frac{1}{2g^2} \text{Tr} \,\, \left( \frac{1}{2}F^2 + (D\phi)^2 + \frac{1}{2}[\phi,\phi]^2 \right) + \ldots + \frac{i\theta}{32\pi^2} \text{Tr} F\tilde{F} $$
(not quite sure about all numerical factors but you can find this Lagrangian everywhere in the literature and the dots denote the fermionic stuff). Then, you know you get a moduli space of vacua which is parameterized by $\langle \phi \rangle \equiv {\bf{a}}= \text{diag}(a^1, \ldots, a^N)$ and with $\sum_i a^i=0$. That is, there are infinitely many degenerate vacua labeled by ${\bf{a}}$. At a specific point of the moduli space the gauge symmetry $SU(N)$ is broken down to $U(1)^{N-1}$ by the Higgs mechanism. So from the content $\{ \phi, A_m, \text{fermions} \}$ we go to $\{ a^i, A_m^{(i)}, \text{fermions} \}$ where $i=1,\ldots, N-1$. The light particles form a $U(1)^{N-1}$ gauge multiplet while the other particles are heavy because of the Higgs mechanism. It is known since the mid 90's that the dynamics of the light particles is encoded in the prepotential $F({\bf{a}},q)$ where $q$ is the instanton counting number. The holomorphic coupling of the effective Lagrangian is written as
$$\tau_{ij}=\frac{1}{2\pi i}\frac{\partial^2}{\partial a^i \partial a^j}F({\bf{a}},q)$$
and this is what we are looking for, the prepotential that determines the low energy dynamics. Generally this is very hard to do since a perturbative analysis is not enough. The solution came by Seiberg and Witten [check Yuji Tachikawa's book, or these notes for example which contain most of what I have been discussing till now anyway]. So, to continue, we need to do something non-perturbatively to answer our question. The key here are the instantons for which we define the instanton number
$$k = \frac{1}{16\pi^2} \int dx^4 \text{Tr} F\tilde{F} $$
with $k\in \mathbb{Z}$always. Combining the usual part of the YM action with the above topological part we arrive at the self-dual and anti-self-dual solutions that minimize the action. Gauge filed configurations on $\mathbb{R}^4$ with instanton number $k$ can be thought of as $k$ blobs of some instanton density. The $k$-instanton makes a non-perurbative contribution to quantum obesrvables of weight $e^{-S_{YM}}=q^k$ where $q\equiv \exp( i\theta - \frac{8\pi^2}{g^2} )$. Note that $q$ cannot be expanded in perturbative series. Then, we can ask ourselves, what is the instanton contribution to $F({\bf{a}},q)$? We can write
$$F({\bf{a}},q) = F_{\text{pert.}}
({\bf{a}},q) \log q + \sum_{q>0}F({\bf{a}}) q^k$$
where the latter is extremelly hard to integrate since it amounts to a path integration over instanton backgrounds. Let us make a topological twist: Fist change the spin of fermions so that only one scalar supercharge remains as
$$ 2 \text{ LH spinors } \lambda_{\alpha}^I \to \lambda_m \text{1 vector} $$
and
$$ 2 \text{ RH spinors } \bar{\lambda}_{\dot{\alpha}}^I \to \bar{\lambda}, \bar{\lambda}_{mn}^{+} \text{ i.e. 1 scalar and 1 self-dual 2-form} $$
and additionally let us restrict our attention to susy invariant operators. Then how do the supercharges act on this topological YM theory?
$$QA_m = \lambda_m, \,\,\,\,\,\,\,\, A\bar{\lambda}_{mn}^{+}= F_{mn}^{+}$$
which is the self-dual solution of the topological YM equation. Thus the path integral localizes to the moduli space with different instanton numbers $k$! That is schematically
$$Z_{\text{instanton}} = \sum_{k \geq 0} q^k \times (\text{ integral over } \mathfrak{M}_k ) $$
where $\mathfrak{M}_k$ is the moduli space pf $k$-instanton, or to say it differently the space of solutions to the self-dual $F_{mn}^{+}=0$ equation.
[Extra] This space has a nice parameterization in terms of some complex matrices that is known as ADHM construction. Nekrasov, studied this path integral which localizes in $\mathfrak{M}_k$. To regularize the volumes he put the YM theory on a special background called $\Omega$-background in which $Q^2$ is not nillpotent which amounts to the requirement that the instantons are of zero size. It turns out that $Z_{\text{instanton}} $ is a quantity more fundamental than the prepotential. Here the instanton configurations are in some sense localized in their moduli space and their regularized volumes are given by sums over fixed-point contributions. Using the fixed point theorem it was possible to find where do they exist fixed points in $\mathfrak{M}_k$ which in the end of the day they are given by a set of Young tableaux. The number of boxes in each Young tableaux is $k$.
In a serious note, the above considerations require a whole course in localization methods and I doubt it will be very helpful to anyone who has not some idea of the pre-requisites (the whole $\mathcal{N}=2$ susy gauge theories and basics of topological YM theory stuff). I personally still find it hard to understand various technicalities of this whole construction and I still have not found a good review or survey of a pedagological style. Maybe Marino's lectures are a bit helpful.