Answer:
Cut the prism into 2 parts like the picture below
Name the upper part A, and the lower part B
Calculate the volume of part A:
12 - 8 = 4 cm
4 * 5 * 6 = 120
Calculate the volume of part B:
15 * 8 * 6 = 720
Volume of the whole prism:
Volume of part A + volume of part B
120 + 720 = 840