Because English law was built around Jesus' teachings since King Alfred. Even if you consider the bible fiction it teaches basic western morality.
Exactly
Where did the Bible come from? (humans wrote it)
The holy texts in all various religions are a distillation of humanity. The stories are very similar in all the books and are generally well battle tested.
I'm just speaking from a western European and North American point of view. Where the relegion has been Christianity for the past thousand years (before state separated from relegion) I still think Christianity echoes through the core laws of English law. But back to the OG point; it doesn't make sense to swear on a belief or bible you don't hold.
I don't think it matters who wrote it, as long as the morals are true, tested and immutable. The Bible was once something everyone agreed on; unifying the culture of a nation. The Bible had a lot of power because everyone agreed with it and acted within it's moral rule sets. In turn, people follow basic law. ...Just like the bitcoin protocol does with it's immutable code.