As Mohan already observed, the [Smith Norm Formal Theorem](https://en.wikipedia.org/wiki/Smith_normal_form) can be extended in your sense to the class of [Dedekind domains](https://en.wikipedia.org/wiki/Dedekind_domain). This is somehow the best we can get:

>> **Claim.** Let $R$ be a Noetherian domain which is not a Dedekind domain. Then there is a maximal ideal $\mathfrak{m}$ of $R$ such that the dimension of $\mathfrak{m}/\mathfrak{m}^2$ over $R/\mathfrak{m}$ is at least $2$. In particular, $R/\mathfrak{m} \times R/\mathfrak{m}$ and $R/\mathfrak{m} \times \mathfrak{m}/\mathfrak{m}^2$ are not isomorphic as $R$-modules although we have $I_0 = R, I_1 = \mathfrak{m}$ and $I_2 = \mathfrak{m}^2$ for an inclusion map $\mathfrak{m} \times \mathfrak{m} \subset R \times R$.


By an inclusion map, I mean any $R$-module homomorphism $f: R^n \rightarrow R^2$ with image $\mathfrak{m} \times \mathfrak{m}$.

>> *Proof.* By hypothesis, we can find $\mathfrak{m}$ such that the  $\mathfrak{m}R_{\mathfrak{m}}$ cannot be generated by a single element as an ideal of the localization $R_{\mathfrak{m}}$ at $\mathfrak{m}$ [1, Theorem 11.2]. Thus the dimension of $\mathfrak{m}R_{\mathfrak{m}}/\mathfrak{m}^2R_{\mathfrak{m}}$ over $R/\mathfrak{m}$ is at least two. As we have $\mathfrak{m}/\mathfrak{m}^2 \simeq (\mathfrak{m}/\mathfrak{m}^2)_{\mathfrak{m}} \simeq \mathfrak{m}R_{\mathfrak{m}}/\mathfrak{m}^2R_{\mathfrak{m}}$, the result follows.

As a result, the Smith Normal Form Theorem can be extended in your sense to an [order](https://en.wikipedia.org/wiki/Order_(ring_theory)) of a [number field](https://en.wikipedia.org/wiki/Algebraic_number_field) if 
and only if this order is maximal.

Let us conclude with a remark on two obvious *generalizations*.

If $R$ is any commutative ring with identity, OP's isomorphism trivially holds whenever $m = 1$. The existence of a Smith Normal Form also trivially guarantees the existence of OP's isomorphism. By definition, every *Elementary Divisor Ring (EDR)* ensure this existence, independently of $m$ and $n$, and there are EDRs which aren't principal ideal rings. The [ring of algebraic integers](https://en.wikipedia.org/wiki/Algebraic_integer) is one instance because of the [principal ideal theorem](https://en.wikipedia.org/wiki/Principal_ideal_theorem), see also this [MO post](https://mathoverflow.net/questions/31275/does-smith-normal-form-imply-pid/31306#31306) for further examples.
 
---

[1] H. Matsumura, "Commutative ring theory", 1986.