A lattice is distributive if it holds the formula \begin{equation} a \vee (b \wedge c) = (a \vee b) \wedge (a \vee c).\tag{D} \end{equation}
There are other equivalent conditions, and one is \begin{equation} (a \vee b = c \vee b \text{ and } a \wedge b = c \wedge b) \Rightarrow a = c.\tag{D'} \end{equation}
A lattice is modular if it holds the formula \begin{equation} a \geq c \Rightarrow a \wedge (b \vee c) = (a \wedge b) \vee c.\tag{M} \end{equation}
What could be a condition (M') for modular lattices, but similar to (D')?
Just add the condition $c \leq a$ to the antecedent of (D'), that is, $$(a \vee b = c \vee b \;\text{and}\; a \wedge b = c \wedge b \;\text{and}\; c \leq a) \implies a = c.$$
Indeed, you can easily find elements in $N_5$ not satisfying the above condition.
But the condition above holds in every modular lattice: \begin{align} a &= a \wedge (b \vee a) \tag{absorption}\\ &= a \wedge (b \vee c) \tag{hypothesis}\\ &= (a \wedge b) \vee c \tag{M}\\ &= (c \wedge b) \vee c \tag{hypothesis}\\ &= c. \tag{absorption} \end{align}