Example 1 (19th Italian Mathematical Olympiad) Let $n$ be a three-digit number, satisfying $100 \leqslant n \leqslant$ 999. Find all $n$ such that the last three digits of $n^{3}$ are equal to $n$.
The original proposition is equivalent to $1000 \mid\left(n^{2}-n\right)=n(n-1)$.
Since $(n, n-1)=1$, and only one of them is even, and $1000=2^{3} \times 5^{3}$, there are the following 4 cases:
(1) $n$ is a multiple of 1000, then $n$ is not a three-digit number.
(2) $n-1$ is a multiple of 1000, then $n$ is not a three-digit number.
(3) $n$ is a multiple of $2^{3}$, and $n-1$ is a multiple of $5^{3}$. Let $n=2^{3} a, n-1=5^{3} b$, then $2^{3} a-5^{3} b=1$. By the Euclidean algorithm, it is easy to know $a=47, b=3$, i.e., $n=376$ satisfies the condition.
(4) $n$ is a multiple of $5^{3}$, and $n-1$ is a multiple of $2^{3}$. Similarly, let $n=5^{3} c, n-1=2^{3} d$, from $5^{3} c-2^{3} d=1$, we get $c=5, d=78, n=625$.