I work for Jobcentre Plus and used to work on a section paying Maternity Allowance (MA.) To qualify for MA, one of the conditions is that yir employer is not liable to pay Statutory Maternity Pay (SMP.)
As long as there's no entitlement to SMP, the fact you left voluntarily will not stop you claiming. There's other conditions you'll need to satisfy but if you have a look here, http://www.dwp.gov.uk/advisers/claimforms/ma1. pdf , it tells you about them.