Formulator: fix FormToXML with a form encoding on py3

The test from 6316d9bb (Formulator: test form serialization with non
ascii elements, 2024-10-24) revealed that form with an encoding other
than UTF-8 are not supported.
17 jobs for zope4py3
in 0 seconds, using 0 compute credits, and was queued for 0 seconds