Most believers find it difficult to answer the question about Cain's wife because they see this dilemma through today's myopic eyes, using their limited human mindsets to try to understand the clear historical record that YHWH has provided.
In a nutshell, the answer to the question as to where Cain got his wife is this:
Remember that YHWH had told man to be "fruitful and multiply" (Genesis 1:28). In Genesis 3:20 we learn that Eve was "the mother of all living" (Genesis 3:21) - and she and Adam were apparently very prolific because by the time we get to Genesis 4 where Cain killed Abel, we see that they had already populated the earth as evidenced in Cain's strange statement:
Genesis 4: 13 Kayin said to ADONAI, "My punishment is greater than I can bear. 14 You are banning me today from the land and from your presence. I will be a fugitive wandering the earth, and whoever finds me will kill me." 15 ADONAI answered him, "Therefore, whoever kills Kayin will receive vengeance sevenfold," and ADONAI put a sign on Kayin, so that no one who found him would kill him.
Who is the "whoever" in the above statement? It HAS to be the brothers and sisters who came before him because - according to Scripture, there is only ONE "Creation". There is absolutely no evidence that YHWH created anyone else "in the beginning" besides Adam and Eve. Obviously, Moshe (Moses) moved through the Genesis account very quickly, and he only mentioned those who were crucial to the Bible story....That's obviously where Cain got his wife, as well. In those days the DNA was pure and untainted.
Because the DNA was pure in those early years, YHWH did not prohibit marriage between close relatives until the time of Moses (see Leviticus 18-20). Based on Genesis 1 and 2, marriage was a one-man, one-woman partnership for life, which meant there was no disobedience to His law in the beginning when close relatives (even brothers and sisters) married. YHWH blessed the union between Abraham and his half-sister (Genesis 20:12) which produced the Hebrew people through Isaac and Jacob. That was approximately 400 years BEFORE He gave Moses the laws to prohibit such marriages.