The answer you found is correct.
We wish to determine the number of ways a total of three numbers can be selected with replacement from the set $\{0, 1, 2, 3, 4, 5, 6, 7, 8, 9\}$. Let $x_k$ denote the number of times the number $k$ is selected, with $0 \leq k \leq 9$. Then the number of ways three numbers can be selected with replacement from the given set is the number of solutions in the nonnegative integers of the equation
$$x_0 + x_1 + x_2 + x_3 + x_4 + x_5 + x_6 + x_7 + x_8 + x_9 = 3$$
A particular solution corresponds to the placement of nine addition signs in a row with three ones. For instance,
$$1 1 1 + + + + + + + + +$$
corresponds to the solution $x_0 = 3$, $x_1 = x_2 = x_3 = x_4 = x_5 = x_6 = x_7 = x_8 = x_9 = 0$, while
$$+ + 1 + + 1 + + + + 1 +$$
corresponds to the solution $x_2 = x_4 = x_8 = 1$, $x_0 = x_1 = x_3 = x_5 = x_6 = x_7 = x_9 = 0$. The number of solutions is the number of ways we can choose which nine of the twelve positions (for three ones and nine addition signs) will be filled with addition signs, which is
$$\binom{3 + 9}{9} = \binom{12}{9}$$
The number of ways $n$ objects can be selected with replacement from a set with $k$ elements is the number of solutions of the equation
$$x_1 + x_2 + x_3 + \cdots + x_k = n$$
in the nonnegative integers. A particular solution corresponds to the placement of $k - 1$ addition signs in a row of $n$ ones. The number of such solutions is
$$\binom{n + k - 1}{k - 1}$$
since we must choose which $k - 1$ of the $n + k - 1$ positions (for $n$ ones and $k - 1$ addition signs) will be filled with addition signs. This is also the number of ways $n$ objects can be selected from $k$ types of objects if there are at least $n$ objects of each type. See combinations with repetition.