In 2-way tables, independence means the cell counts are
given by the marginals.
In 3-way tables, we have three pairs of variables (A*B, A*C
and B*C), but a 3-way tabulation (A*B*C): more complex:
We could have overall 3-way independence: knowing the 1-D
A, B and C margins (frequencies) is enough to predict the
cell counts in the 3-way table.
We could have any one, two or all three of the 2-way
interactions - pairwise associations.
We could need the A*B*C interaction, if the association
between e.g., A and B differs across the categories of C (if
this is true then in general the association between A and C
differs across B, etc. ).
The equation for a saturated model of a three-way table is