12 is popular because it has so many divisors (1, 2, 3, 4, 6, 12) — splitting the width in half, thirds or quarters always lands on whole columns. It carries over from print grid systems, and frameworks like Bootstrap made it the web's default.
With CSS Grid you set grid-template-columns: repeat(12, 1fr) and then just declare how many columns each element spans — grid-column: span 4 — with no manual column-number bookkeeping like old float-based grids needed.
Columns and gutters (the gaps between columns) are separate concepts — see the gutter entry. Responsively, the usual move is to keep 12 columns fixed and change each element's span per breakpoint: span 12 on mobile, span 4 on desktop.
When to use
A solid default for marketing sites, blogs and dashboards that need consistent content widths across many pages.