The more generations there are between you and your cousin’s common ancestor, the more possible it is that you and your cousin did not inherit the same segment of DNA from your common ancestor. Inheritance is a random process and you may find that you do not share a detectable amount of DNA with a known 4th cousin, yet that you do share some DNA with your 5th to 8th cousins.