Here is a simpler argument, combining 1--6 into one step.
Let $G$ be a countable abelian group generated by $x_1,x_2,\ldots$. Then a Følner sequence is given by taking $S_n$ to be the pyramid consisting of elements which can be written as
$a_1x_2+a_2x_2+\cdots+a_nx_n$ with $\lvert a_1\rvert\leq n,\lvert a_2\rvert\leq n-1,\ldots,\lvert a_n\rvert\leq 1$.
The invariant probability measure is then defined by $\mu(A)=\underset{\omega}{\lim}\lvert A\cap S_n\rvert / \lvert S_n\rvert$ as usual.
A more natural way to phrase this argument is:
- The countable group $\mathbb{Z}^\infty$ is amenable.
- All countable abelian groups are amenable, because amenability descends to quotients.
But I would like to emphasize that there is really only one step here, because the proof for $\mathbb{Z}^\infty$ automatically applies to any countable abelian group. This two-step approach is easier to remember, though. (The ideas here are the same as in my other answer, but I think this formulation is much cleaner.)
2016 Edit: Here is an argument to see that $S_n$ is a Følner sequence. It is quite pleasant to think about precisely where commutativity comes into play.
Fix $g\in G$ and any finite subset $S\subset G$. We first analyze the size of the symmetric difference $gS\bigtriangleup S$. Consider the equivalence relation on $S$ generated by the relation $x\sim y$ if $y=x+g$ (which is itself neither symmetric, reflexive, or transitive). We will call an equivalence class under this relation a "$g$-string". Every $g$-string consists of elements $x_1,\ldots,x_k\in S$ with $x_{j+1}=x_j+g$.
The first key observation is that $\lvert gS\bigtriangleup S\rvert$ is at most twice the number of $g$-strings. Indeed, if $z\in S$ belongs to $gS\bigtriangleup S$, then $z$ must be the "leftmost endpoint" of a $g$-string; if $z\notin S$ belongs to $gS\bigtriangleup S$, then $z-g$ must be the "rightmost endpoint" of a $g$-string; and each $g$-string has at most 2 such endpoints (it could have 1 if the endpoints coincide, or 0 if $g$ has finite order).
Our goal is to prove for all $g\in G$ that $\frac{\lvert gS_n \bigtriangleup S_n\rvert}{\lvert S_n\rvert}\to 0$ as $n\to \infty$. Since $\lvert abS\bigtriangleup S\rvert\leq\lvert abS\bigtriangleup bS\rvert+\lvert bS\bigtriangleup S\rvert= \lvert aS\bigtriangleup S\rvert+\lvert bS\bigtriangleup S\rvert$, it suffices to prove this for all $g_i$ in a generating set.
By the observation above, to prove that $\frac{\lvert g_iS_n \bigtriangleup S_n\rvert}{\lvert S_n\rvert}\to 0$, it suffices to prove that $\frac{\text{# of $g_i$-strings in $S_n$}}{\lvert S_n\rvert}\to 0$. Equivalently, we must prove that the reciprocal $\frac{\lvert S_n\rvert}{\#\text{ of $g_i$-strings in $S_n$}}$ diverges, or in other words that the average size of a $g_i$-string in $S_n$ diverges.
We now use the specific form of our sets $S_n=\{a_1g_1+\cdots+a_ng_n\,|\, \lvert a_i\rvert\leq n-i\}$. For any $i$ and any $n$, set $k=n-i$ (so that $\lvert a_i\rvert\leq k$ in $S_n$). The second key observation is that every $g_i$-string in $S_n$ has cardinality at least $2k+1$ unless $g_i$ has finite order. Indeed given $x\in S_n$, write it as $x=a_1g_1+\cdots+a_ig_i+\cdots+a_ng_n$; then the elements $a_1g_1+\cdots+bg_i+\cdots+a_ng_n\in S_n$ for $b=-k,\ldots,-1,0,1,\ldots,k$ belong to a single $g_i$-string containing $x$. If $g_i$ does not have finite order, these $2k+1$ elements must be distinct. This shows that the minimum size of a $g_i$-string in $S_n$ is $2n-2i+1$, so for fixed $g_i$ the average size diverges as $n\to \infty$.
When $g_i$ has finite order $N$ this argument does not work (a $g_i$-string has maximum size $N$, so the average size cannot diverge). However once $N<2k+1$, the subset containing the $2k+1$ elements above is closed under multiplication by $g_i$. In other words, once $n\geq i+N/2$ the set $S_n$ is $g_i$-invariant, so $\lvert g_iS_n\bigtriangleup S_n\rvert=0$.
I'm grateful to David Ullrich for pointing out that this claim is not obvious, since the quotient of a Følner sequence need not be a Følner sequence (Yves Cornulier gives an example here).
Best Answer
I am also unsure of what "nontriviality" conditions you want to impose. Without any further conditions, the following answers your question:
Call a positive integer $n$ nilpotent if every group of order $n$ is nilpotent.
Call a positive integer $n$ abelian if every group of order $n$ is abelian.
Suppose that the prime factorization of $n$ is $p_1^{a_1} \cdots p_r^{a_r}$. Then:
$n$ is nilpotent iff for all $i,j,k$ with $1 \leq k \leq a_i$, $p_i^k \not \equiv 1 \pmod{p_j}$.
$n$ is abelian iff it is nilpotent and $a_i \leq 2$ for all $i$.
These results are proved in
Pakianathan, Jonathan(1-WI); Shankar, Krishnan(1-MI) Nilpotent numbers. Amer. Math. Monthly 107 (2000), no. 7, 631--634.
The proofs are constructive: for any $n$ which is not nilpotent (resp. abelian), they give an explicit group of that order which is not nilpotent (resp. abelian).
The paper is available at
http://alpha.math.uga.edu/~pete/nilpotentnumbers.pdf