If you are doing volunteer work for a qualified charity (one recognized by the IRS, which includes all the well-known charities as well as churches, etc.), then you can deduct on Schedule A as a charitable contribution any actual expenses you incurred in doing the work. This can include mileage, etc.
What you cannot do is get a deduction for your time.
Take a look at IRS Pub 526 at the top of page 5.