Non-Abelian geometric quantum memory with an atomic ensemble