Notice that there are 6 sums of 7 on the table provided. For example rolling a 1 and then a 6 would produce a sum of 7.
The reason the answer is 12 and not 6 is that you need to double it for the two dice. Let's say one die was green and the other was blue. The green die could be the 1 and the blue die could be the 6. That is one favorable outcome, but it could be switched. Maybe the green die was 6 and the blue die was 1.