In the original world, there were supposedly known ways to avoid the consequences of inbreeding, but they had been banned after the formation of the Ministry of Magic over time. The knowledge of them had slowly been forgotten and faded in history, just like many other magical branches and disciplines.