In TES lore, soul trapping humanoids is related to necromancy and is believed to be immoral. However, soul trapping creatures is perfectly acceptable.
According to Skyrim Wiki, this is because:
The souls of humanoids trapped in these soul gems remain conscious. They are generally regarded as unethical, and their use is prohibited at The College of Winterhold, despite the institution's lenient stance on the practice of Necromancy. Soul Trapping humanoids is considered a crime in many of Skyrim's Holds.
However, I am unable to find any justification for this from in-game sources.