In section two of "An Occurrence at Owl Creek Bridge," the literary device Ambrose Bierce uses is flashback.
Section one of the story describes a scene in which a man is about to be hanged from a bridge. The reader doesn't know who the man is or what his crime was. Section two explains both of those things by using a flashback. A flashback is an interruption that an author will use to narrate past events. The purpose is to provide background or context to current events in the story. Section two explains that the man being hanged is Peyton Farquhar. He is a southern plantation owner. Additionally, he is eager to find some way to be a part of the southern fight against the Union.
Circumstances of an imperious nature, which it is unnecessary to relate here, had prevented him from taking service with that gallant army which had fought the disastrous campaigns ending with the fall of Corinth, and he chafed under the inglorious restraint, longing for the release of his energies, the larger life of the soldier, the opportunity for distinction. That opportunity, he felt, would come, as it comes to all in wartime.
A Federal scout, posing as a Confederate soldier, informs Farquhar of the Union's position at Owl Creek Bridge. Farquhar is tempted to find some way to sabotage the bridge, and the scout feeds that temptation by telling Farquhar how the bridge might be destroyed.
The soldier reflected. "I was there a month ago," he replied. "I observed that the flood of last winter had lodged a great quantity of driftwood against the wooden pier at this end of the bridge. It is now dry and would burn like tinder."
Once the flashback ends, the reader immediately returns to Farquhar falling from his position on the bridge.