Because it means more resources for them. As was explained to me in college by an African professor, Africans tend to be very communally oriented. A village, or nowadays an urban neighborhood, is populated by extended families and in-laws of each other, who are all responsible for looking after their distant relatives. The more kids a family has, the more they can marry the daughters of the other families, or marry their daughters to their sons.
It also means more work. Child labor is expected in Africa, so African children traditionally helped on the farm, the fields, the cattle herds, etc. Today this has been expanded into all sorts of awful jobs like child prostitutes or the kids in Ghana who sort through international scrapyards to look for hard-drives, which they sell to organized crime (this is how Africans can get your bank account info) who once they go through it, sell it back to the kids so they can bake the gold out of the hard drive (or motherboard/other computer parts).
And if you're wondering, yes, this is part of why Africa is so corrupt, because if those kids grow up and get into politics, they are socially expected to send money back to their village/neighborhood. And yes, displays of status go a huge way in Africa, so that's also why politicians do shit like buy expensive foreign cars or most famously, when the dictator of Ivory Coast moved the capital to his home village (an insignificant place) and built an enormous cathedral there.
Does this happen in poor slav countries? Poor american countries? Poor asian countries? No?
So the common denominator isn't "poor countries" specifically.
It used to until very recently. The neo-Malthusian Bible "The Population Bomb" was written during a time when Latin America exploded in population (i.e. Guatemala went from 2 million people in 1921 to 17.6 million in 2021). The Russian Empire's population more than tripled during the 19th century, and it took two world wars, a civil war, famine, an insanely high level of emigration, and intensive communist family planning to keep the population low in the 20th century. The infamous "One Child Policy" was put in place because Mao was absolutely terrified by the sheer number of people being born.
Africa can't have family planning because in addition to religion, they are all very tribalist. Not having more kids means the other tribe is having more kids. The government is usually controlled by one tribe and their allies, so the government does not want to offend their own political allies and rival tribes consider it a plot against them. This happens everywhere, hell that's part of why blacks in the US have more babies because they ain't listening to no cracka telling them to use birth control/get a vasectomy.