The Gramps Wiki includes the page: GEPS 027: Gender as an Entry Field. It address the exact issue you are bringing up with Gramps, i.e. that the categories of Female, Male and Unknown do not allow you to catalog some people. This is addressed as "a mistake which continues to invisiblize and alienate people".
This page includes a proposed solution (create a GenderType class) which would allow people to select Male, Female or Unknown, but also allow them to fill in their own genders. The page then discusses how extensive the change would be, concerns, has a "see also" section, and lists resources.
This page was last edited in 2 January 2016. So this is a known issue in Gramps.
The page also references Feature Request 5730 that is in the Gramps Bugtracker, The issue summary used to be "Make Gramps more functional for LGBT data" but was changed to "Codes for the representation of human sexes". This issue was created in May 2012, is classified major, and is still marked open.
If you look at the Activities section (i.e. the discussion) on that page, it appears that dsblank created an OtherGender.patch for the Gramps program back in May 2012, and npigeon followed that up with a gender-entry-field.patch a few days later.
Further in that discussion, you'll see that in February 2020, TheGhostHybrid wanted to apply the patch. User4319 told him the patch was made for a very old version of Gramps and would need to be updated.
So there were two patches made, but neither work for the current version of Gramps.
You likely should make yourself known on the Gramps bugtracker and comment on Issue 5730 to make it known that you are another user in need of this patch. Maybe you can prompt some escalation of this issue, which the Gramps developers have known about for a long time but don't currently have a solution for.
In the meantime, there is a suggestion of what you can choose to do now without waiting for changes to Gramps if the issue you are dealing with is a transgender person:
In the Gramps mailing list, in May 2017, Nick Hall asked about entering a transgender person.. There are several different ideas in that thread that may or may not apply in your case, including:
- Enter birth gender
- Create a custom event for a sex change operation
- Enter both a female name and a male name for the person
- Enter gender as to how the individual identifies (if male or female)
- Make the birth name a secondary name
- Attach a note to the birth name mentioning the original gender
- Add a custom event of "transition"
One of those suggestions may give you an idea of a way to represent your nonbinary person.