Take the simplest model: One after the other of the balls is thrown at random into one of the boxes $a$, $b$, $c$. There are $3^{12}$ different possible histories for that, all of them equiprobable. The number of histories leading to a particular final content $(r,s,t)$ of the three boxes is the coefficient of the term $a^r b^s c^t$ in the expansion of $(a+b+c)^{12}$, i.e., is given by ${12!\over r!\>s!\>t!}$.
There is the question whether "one of the boxes" means "at least one of the boxes", or "exactly one of the boxes". Since one sentence later they talk about "exactly three balls" my working hypothesis is that "at least one of the boxes" is meant.
For the probability in question we have to consider the contents
$$(3,9,0), (3,8,1), (3,7,2), (3,5,4)$$
each of them in six orders, and $(6,3,3)$ in three orders. The total number $N$ of "admissible" histories is therefore given by
$$N=6{12!\over3!}\left({1\over9!}+{1\over8!}+{1\over 7!\>2!}+{1\over 5!\>4!}\right)+3{12!\over 6!\>3!\>3!}=282\,480\ ,$$
and the required probability $P$ is $$P={N\over 3^{12}}\doteq0.531536\ .$$
The first case makes an ordering out of the boxes. In other words, your result is an ordered pair, i.e. cutting $7$ objects, $(3,4) \ne (4,3)$.
If you cannot distinguish the boxes, the result is a set, and $\{3,4\} = \{4,3\}$ so the first answer for this case is a massive overcount, but by how much?
Best Answer
Your first approach is indeed correct. Here is an alternate (much more laboriously exhaustive) way of thinking about the problem:
Part I
You can reformulate the problem, by instead thinking about arranging two types of "tiles": (A) a box containing a ball, and (B) a box lacking a ball, followed by a box containing a ball.
For example, suppose $n=9$ and $k=6$. In this case, you must have $n-k=3$ empty boxes. Thus, you will have $n-k=3$ of "tile B". This leaves $n-2(n-k)=2k-n=3$ balls to be used as instances of "tile A".
To illustrate the idea: let $(1)$ denote "tile A", i.e. a box containing a ball, and let $(01)$ denote "tile B", i.e. a box lacking a ball followed by a box containing a ball. Here are a few arbitrary arrangements of these "tiles":
$$ (1)(1)(01)(1)(01)(01) = 1,1,0,1,1,0,1,0,1 \\ (01)(01)(1)(1)(1)(01) = 0,1,0,1,1,1,1,0,1 \\ (01)(1)(1)(01)(01)(1) = 0,1,1,1,0,1,0,1,1 $$
As you may observe from these examples, we have $(n-k)+(2k-n)=k$ total "tiles", out of which we must choose $n-k$ positions for the $(01)$s. The total number of ways we can do this is $\binom{k}{n-k}$.
Part II
At this point, we run into a problem: our two tiles $(1)$ and $(01)$ admit every way to produce a sequence with ends with a filled box, i.e. $1$... but no way to produce a sequence which ends with an empty box, i.e. $0$. For example, the following are valid ball arrangements with no two consecutive empty boxes, but there is no way to divide them up into $(1)$ and $(01)$ only:
$$ 0,1,0,1,1,1,1,1,0 = (01)(01)(1)(1)(1)(1)0 \\ 1,0,1,1,1,1,0,1,0 = (1)(01)(1)(1)(1)(01)0 \\ 1,1,1,1,0,1,0,1,0 = (1)(1)(1)(1)(01)(01)0 $$
Thus, we must introduce a new tile: let $(0)$ denote "tile C". However, "tile C" comes with a couple of very specific restrictions: (i) it can only appear at most once in any tile set, and (ii) if it does appear, it must be the very last tile. These restrictions make it so that we can effectively ignore "tile C" when enumerating the sequences of boxes which end with an empty box.
For example: in the three sequences shown above which end in $0$, we can effectively just ignore the $0$ as it does not affect anything, and observe that from $k$ "tiles", we must choose $n-k-1$ positions for the $(01)$s.
Part III
In Part I, we showed that the number of combinations which end in $1$ is $\binom{k}{n-k}$. Subsequently, in Part II, we showed that the number of combinations which end in $0$ is $\binom{k}{n-k-1}$. "Combinations which end in $1$" and "combinations which end in $0$" are two mutually exclusive, collectively exhaustive sets, which together comprise the set of all possible combinations. Thus, the total number of possible combinations is simply the sum of the two results from Parts I & II:
$$ \binom{k}{n-k} + \binom{k}{n-k-1} \\ = \binom{k+1}{n-k} $$
Note that this solution is valid only when $n/2 \le k \le n$; if not, then the answer is $0$. If $k < n/2$, then there are less than half as many balls as boxes, which makes it impossible to avoid two consecutive empty boxes occurring somewhere. And if $k > n$, then there are more balls than boxes, which by the pigeonhole principle implies that at least one box must have two or more balls.
Brute force check with Python 3.x
The following Python script does the following: for $1\le n \le 20$, and for $\lceil{n/2}\rceil \le k \le n$, (i) manually lists out all the distinct valid combinations, and counts them; and (ii) calculates the number of distinct valid combinations, by way of $\binom{k+1}{n-k}$. The output confirms that for each checked $(n,k)$, the values from (i) and (ii) agree.
Output: