The 364th prohibition is that a king is forbidden from having too many wives.

The source of this prohibition is G‑d's statement1 (exalted be He), "He must not have too many wives."

The limit is that he may not have more than 18 wives legally bound by kesubah and kiddushin.2

The details of this mitzvah are explained in the second chapter of tractate Sanhedrin.3 Whenever he adds on to this limit, he is punished by lashes.