I really don't think it's 40k that causes the lower ratio of female gamers. More like the overall preference society gives men and women for certain things that they will grow up to consider 'girl things' and 'boy things'. That's what does it, you don't need to change 40k, you need to change the common outlook overall. It also doesn't help that the stereotype of many gamer males not being able to deal reasonably with a female entering the vicinity is accurate in the case of a few people, and that's enough to make it a problem which inevitably discourages them from getting involved. It only takes one to put someone off.
40k is probably one of the most gender-equal settings around. 40k isn't the problem, it's people around it from both sides of the 'screen'.
It's important to remember what 40k is based on. It's an amalgamation of various previously existing sci-fi and fantasy things which gradually grew into an entity of its own. Astartes are all male because they're meant to be a cross between monks (a monastery populated only by males) and the Saudakar, the fanatical super soldiers in service to the emperor in Dune. The Sororitas are meant to be a cross between nuns and the Fish Warriors, the fanatical all-female army in service to the god-emperor in Dune. The Militarum (let's just roll with it shall we?) are mixed as normal because they're the army. Starship Troopers style. The Arbites and Enforcers are Judges, mixed as normal.
The only reason astartes and sororitas are all-male and all-female respectively is because that's what they're based on, all-male and all-female groups from history and previous sci-fi (specifically Dune), not some misogynistic obsession. Look at the Eldar, male and female Eldar of all kinds from Craftworld to Commoragh are stated to be equal in every way including physically, with the only exception being that Dark Eldar Wyches usually only rise above the base rank if they're female. They give the reasoning that supposedly the women are capable of becoming more flexible and agile than the men, but I think it's mainly because they had called the top rank 'Succubus' and the male equivalent 'Incubus' was already a thing. Pretty much everything in 40k is gender equal. As I've said, the astartes, sororitas and wych cults are as they are for specific reasons, not outright sexism.
I will say that the way in which the female models are sculpted does bug me, they all have ridiculously oversized chests as if that was the only way to get across that they're female, but that really comes across as trying to show that the model is female and getting the proportions dodgy rather than kingdom death style model-porn. The models don't do it will, but the background does equality very well. Look at the inquisition. Most powerful organisation in the Imperium, no distinction in gender ratio.