We study the effect of inhomogeneous coupling between atoms and external light fields on quantum memories that employ electromagnetically induced transparency (EIT). By introducing atomic subensembles to describe the present inhomogeneous coupling case we find that there is a nonsymmetric dark-state subspace that allows the EIT quantum-memory technique to function perfectly. This shows that such a memory scheme can work ideally even if the atomic state is very far from being a symmetric one.