"Worth" is used as an adjective and a noun also.
As an adjective, worth is followed with noun/ V-ing.
The 3 examples you took could be correct in this way:
1.Doing voluntary work is worthwhile.
2. It's worth doing voluntary work.
3. Even though we have to sacrifice a bit, I think it's worth it.
- For Teachers