Of course. But in theory you have to ask permission from your manager. It is often sufficient to inform the employer that you are doing volunteer work.