The likelihood that you will read my answer is slim, but perhaps someone else will read it and benefit inshaAllah. I'd like to address your two questions.
"If Allah forbids homosexuality, then why does he allow people to be born gay?"
So first of all, the Qur'an does not explicitly talk about sexuality (heterosexuality, bisexuality, homosexuality, or asexuality.) It does refer to sex acts and desire. You can think of sex as sex acts and sexuality with feelings of desire. Sex may be part of sexuality, but sexuality is more than that. Sex can also be separate from sexuality (e.g. rape of an individual is a sexual act that occurs to that person's body against their will. The sex act of rape is not related to that person's sexuality or desire or their identity.)
My understanding is that Allah SWT does not forbid homosexuality, and, in fact, Allah SWT created a diversity of human beings. The Qur'an states that variety in appearance, language, culture, and even religion were created as part of Allah SWT's plan and wisdom. Perhaps you think that all that diversity was created by Allah SWT but not sexual diversity. We know homosexuality exists among human beings, the only creatures with free will. But homosexuality also exists among animals, and they do not have free will, and they are only obedient to Allah SWT. In Surat al-Rum (Qur’an 30:22), it says that Allah has created human beings with different alwan, a word that can mean both “colors” and “tastes.” And human beings do have different tastes in many things -- including sexuality.
The Qur'an even mentions sexual diversity. In Surat al-Nur (Qur’an 24:31-24:33), there is specific mention of "men who are not in need of women". These men have been gay or asexual, but they certainly were not heterosexual men.
The Prophet pbuh even knew people who fit that description of "men who are not in need of women". There are studies of early Islamic literature showing that the Prophet accepted men called mukhanath. These were men who were "acting like women", so perhaps gay men whose sexual orientation was seen as making them "act like women" or transgender people.
The Prophet pbuh even recognised these men as different than others. His wife, Umm Salama, had a male friend named Hit who was one of these mukhanath. He was allowed to enter both the men's space and the women's space. The Prophet pbuh even trusted him enough to let him enter the private women's spaces. (As a side note, after Hit was caught describing a woman's body to another male, the Prophet pbuh forbid Hit from entering the private women's spaces again, but there was no punishment for being mukhanath, but rather for violating privacy.)
The Prophet pbuh never punished anyone for homosexuality or homosexual acts. After the Prophet pbuh died, his companions once discussed whether to punish a person for homosexuality. If the Prophet pbuh had ever done so, his companions would have simply followed his previous decision. Since they didn't know what to do, it's clear that the Prophet pbuh had never punished someone for homosexuality or given an example for those companions to follow.
The Qur'an does not have a word for homosexuality within it. There are several other words used to talk about sexual behaviour though.
- fahisha meaning "doing something that is not allowed" or "transgression". This can include other activities that are not sexual.
- zina, the only word in the Qur'an for a transgression that is definitely sexual. Zina means "adultery".
- fisq or fusuq meaning "corruption". This is used to describe the mind of someomone doing something that is not allowed, so someone comitting fahisha.
Some scholars do try to connect those three terms with homosexuality. This connection between fahisha and fusuq with homosexuality is not clear from the Qur'an though, and the Qur'an simply does not make a connection between zina and homosexuality. Human jurists have made that statement, but it is nowhere in the Qur'an.
While the Qur'an spends most of its time in discussions of relationships discussing heterosexual relationships, that does not meant that homosexuality is wrong. It is simply more unusual. The Qur'an does discuss people who are intersex (with signs of being both male and female) as well as the aforementioned "men who have no need of women" (who may have been gay, transgender, or asexual.)
Prophet Lut's pbuh Story
This is a very succinct approach to the story of the Prophet of Lut pbuh.
In the story, the Prophet Lut (PBUH) first advised the people of the city of Sodom to follow God’s path, but they ignored him. Later, the
men of Sodom threatened to rape Lut’s male visitors, who were angels
disguised as men. God then punished the entire city of Sodom for
rejecting their Prophet (Lut) and for “transgressions.”
Some scholars interpret the “transgressions” in the story of Lut to
refer to male homosexuality. Yet the word “transgressions” in the
Qur’an can mean something sexual or something non-sexual. Men were not
the only ones punished in the destruction of Sodom. According to the
Qur’an, the whole city was destroyed. Lut’s wife is specifically
mentioned. Were Lut’s wife, other women and the children of Sodom
punished for male homosexuality? That does not seem to be a reasonable
A thematic reading of the story of Lut can be found in the Qisas
al-Anbiya (classical stories of the Prophets). A story written by the
scholar Muhammad ibn Abdallah Al-Kisa’i puts the strange behavior of
the men of the city of Sodom in a context that makes sense. Al-Kisa’i
suggests that the people of Sodom had taken to showing their city’s
dominance by raping strangers. They were showing that they could take
what they wanted from others. In that way, people became afraid to
raid the city. This showed aggressiveness, stinginess and greed—all
things that would justify their punishment. A thematic reading also
tells us that the story’s main purpose was to show that people had
rejected their prophets in the past, as some rejected Muhammad during
his lifetime, and how those who rejected prophets were punished. This
is clear from the context of the story of Lut, which is placed among
other stories with the same theme.
Once again, the behaviour of the men of Sodom was not an expression of sexual desire. They wanted to have sex with the visiting angels by force. That is rape. Rape is about power and coercion/control/punishment of the victim. The people of Sodom were punished for the transgression of rape, greed, and stinginess.
Also, being gay, is it haram for me to marry a woman, or would it be haram for her to marry me?
It would not be haram for you to marry a woman, but it would probably not be the most fulfilling relationship you could be in, nor would it be compassionate or truthful to your spouse who deserves someone who would love her in many ways, including sexually. If you are gay and you meet someone with whom you would like to commit your life to, to support and grow in a marriage, then go along with that. If you're gay, that person would be a man. If not, you do not need to be married to be a good Muslim.
There are many LGBTQ Muslims who are observant and who are married to those of the same sex. In fact, there are gay imams in Australia, South Africa, Germany, the United States and around the world.
There are also prayer and social groups for LGBTQ Muslims. These include ones in South Africa, Canada, the United States, the UK, and many more countries including Egypt, Sudan, Palestine, Pakistan, Serbia, Turkey, Morocco, Bangladesh, France, the Netherlands, Tunisia, and the UAE.
There are many more resources you can use to learn more about homosexuality and its place in Islam. This is a simple explanation. Further reading includes Homosexuality in Islam: Critical Reflection on Gay, Lesbian, and Transgender Muslims by Scott Siraj al-Haqq Kugle. There are many LGBTQ Muslims and you don't have to choose between your sexuality and your deen.
You, and all LGBTQA+ Muslims, are in my duas.