Not sure why everyone seems to think you can't shorten a mat leave contract. You can, assuming it is written into the contract. They just need the appropriate notice which is usually 4 weeks/ a month. This has to be done because women can request to come back earlier than they originally planned and usually an employer would want to accommodate this. Obviously it depends on the company, but I work for a large global company and this is what we do. I would also suggest requesting the 12 months and coming back early if necessary. This is what we recommend at work as it is generally easier to work around that planning for someone to come back later than planned. And tbh, most people don't end up coming back early.

They definitely can't refuse you to work up until 4 weeks before the EDD, as others have said.