To be sorry is to feel regret or feel bad about something — usually something you did. "I'm sorry" is an apology.
If you're feeling sorry about something, then you're feeling a combination of sadness and regret. You can be sorry for things you did, and you can also be sorry for bad things that happen to other people that don't involve you. At a funeral, people say "I'm sorry for your loss." The word sorry can also be used as an adjective to mean shoddy or crappy, as in "That is one sorry excuse!"