In this example, the

amplitude a = 12, and
b = 2, so the period = 2π/b = 2π/2 = π, and

math expression

so the phase shift is

math expression

This means we need to move the cosine graph to the right of its normal position (because the displacement is positive in this example) by π/16.

Without phase shift, the cosine curve will be y = 12 cos 2x and its graph is as follows:

12 cos 2x

Now, let's shift it to the right by π/16 ≈ 0.1963:

shifted

You can see the original cosine curve (in gray) and we have shifted it by π/16 to the right to give the required graph of y = 12 cos (2x − π/8), in blue.