A non-trivial group $(G,\circ)$ does not have any proper subgroups if and only if $\text{ord}(G)=p$,where $p$ is a prime number.
$\Longleftarrow$ If $(G,\circ)$ is a group of prime order, then Lagrange's theorem implies that the order of the subgroups of $G$ divides $p$, which happens if the order is either $1$ or $p$, and hence the subgroups are improper subgroups of $(G,\circ)$, shows the only subgroups of $G$ are proper ones.
$\Longrightarrow$ Assume $(G,\circ)$ does not have any proper subgroups, if $G$ is not cyclic then it's generated by two distinct elements (generators) $a,b \in G$ (such elements exist since $G$ is non-trivial), Hence $\langle a\rangle$ and $\langle b\rangle$ are two distinct proper subgroups of $G$, a contradiction. (I think it's not true to say "two" distant proper subgroups, since it may happen that one of them is the identity element of $G$, but in either case at least one of them is a proper subgroup of $G$ ad this leads to the desired contradiction)
Now we should show that $G$ is a finite group (I guess we need to show that if $G$ is generated by an element $g \in G$, and does not exist a positive integer for which $g^n=1$ does hold, then this leads to a contradiction). For the prime part, If $n$ is a composition number then we can find a prime number $m <n$,then $\langle g^m\rangle$ has order $\frac{n}{\gcd\left(m,n\right)}$,how to get the desired contradiction?
One direction is clear by Lagrange (since $p$ has no divisors).
For the converse, if $G$ is finite, we could use Cauchy's theorem to get an element of order $p$, where $p||G|$. Then the cyclic group generated by that element has to be the whole group.
If $G$ is infinite, we can just take an element and consider the cyclic subgroup it generates. It must be the whole thing. So we have $\Bbb Z$. But $\Bbb Z$ has nontrivial proper subgroups. So $G$ can't be infinite.