Actually, you're pretty much spot on. The word you want is "irreducible", rather than "indivisible". In general rings there are irreducible elements and prime elements, and they have different definitions. You're looking for a unique factorisation into irreducibles.
https://en.wikipedia.org/wiki/Irreducible_element https://en.wikipedia.org/wiki/Prime_element