An undergraduate level example where the set of commutators is proper in the derived subgroup.

Solution 1:

This publication On Commutator Groups, by Kappe and Morse is great to read. Among many, it contains the following theorem:
If $G$ is a finite group with $|G : Z(G)|^2 < |G'|$, then there are elements in $G'$ that are not commutators.
With the help of this one can construct a large family of groups of nilpotency class 2 with the property that the set of commutators is not equal to the commutator subgroup.