The elephant represents the narrator's conscience, which he tries to ignore (it is the proverbial "elephant in the room.")
Here is an excerpt on the theme and symbolism of the elephant from eNotes. You can learn more about this and other elements of Orwell's gripping tale by visiting the link below.
"His official position, rather than his moral disposition, compels the narrator to act in the way that he does, so as to uphold his office precisely by keeping the native Burmese in their subordinate and dependent place. As a colonial official, the narrator must not let himself become a spectacle before the native crowds. Not shooting the elephant would make him seem like a coward, so he shoots the elephant. The narrator’s moral conscience appears in the moment when the corpse of the Burmese crushed by the elephant comes to his attention; the narrator says that the man lay sprawled in a ‘‘crucified’’ posture, invoking all of the poignant and rich symbolism that the term ‘‘crucified’’ offers. The elephant, too, especially in its pain-wracked death, evokes in the narrator feelings of terrible pity, not soothed by his knowledge that he acted within the law. Law, indeed, opposes conscience in ‘‘Shooting an Elephant.’’ The brute fact of Empire, thoroughly institutionalized, is irreconcilable with the individual’s moral analysis of the situation."