 He worked under Balakirev in the Court Chapel as a deputy until 1894, which allowed him to study Russian Orthodox church music.He also taught classes at the Chapel, and wrote his textbook on harmony for use there and at the Conservatory.Rimsky-Korsakov's studies and his change in attitude regarding music education brought him the scorn of his fellow nationalists, who thought he was throwing away his Russian heritage to compose fugues and sonatas.