View $A$ as a linear map from $\mathbb{K}^n$ t0 $\mathbb{K}^m$. Then by the fundamental theorem of linear maps, we have $$\text{dim }\mathbb{K}^n = \text{dim null }A + \text{dim range }A.$$ Since $\text{dim }\mathbb{K}^n = n$ and $\text{dim range }A = \text{rank }A$ we get $$\text{dim null }A = n - \text{rank }A.$$ If $\text{rank }A < n$, then $$\text{dim null }A \geq 1,$$ which means that $A$ has a nonzero nullspace. If you fill the columns of $B$ with vectors in the null space of $A$ then $AB = 0$.