Pretty sure slang goes back much further than the Civil War.
During the Hundred Years War, the French called English troops "goddams" because English troops used this curse word with some frequency
Some slang is also a result of sexual references, words like "punk" and "pogey". "Punk" is sometimes used simply to to mean a young, supposedly inexperienced or ignorant person ... but the original meaning is darker.
Would guess a fair amount of slang came out prisoner sub-cultures.
During the Hundred Years War, the French called English troops "goddams" because English troops used this curse word with some frequency

Some slang is also a result of sexual references, words like "punk" and "pogey". "Punk" is sometimes used simply to to mean a young, supposedly inexperienced or ignorant person ... but the original meaning is darker.
Would guess a fair amount of slang came out prisoner sub-cultures.

Fire In The Hole