On the market for rentals, gender and ethnicity is, by law, protected from discrimination. You can therefore not choose or reject a tenant based solely on their nationality or gender. This also means that you cannot write that you prefer (or not prefer) a certain gender or nationality.
This does not apply if the lease is part of your home – e.g. if you are renting out a room in your house. If this is the case, you are free to decide whether you prefer a male or female tenant and this may also be specified in the ad text.
However It is still against the law to choose a tenant based on nationality/ethnicity but the you are allowed to prefer fx a English speaking individual etc. if you for example are having difficulties speaking other languages.