Hi @Arie,
According to the website of the German Embassy in Sanaa, legalisation is not possible there or at other embassies. I advise you to inform the Standesamt of this situation.
If the Standesamt insist on having documents legalised, your partner can offer to make a statutory declaration (in German 'Versicherung an Eides') about the information the Standesamt needs, for example about their marital status. This is covered in paragraph 9 of the Personal Status Act. It says that if it is not possible for a person to provide the documentation necessary, they can provide alternative documentation proving their status. If this is also not possible, then a statutory declaration can be accepted in place of the documentation.
Best,
Éanna