Sherlock is premised on him being a genius, a particular kind of genius who is sensitive to minute details leading to conclusions, ie one detail in a particular location/pattern leads to a particular conclusion.
(Most INTJs are poor at the detail observation, but decently good at the pattern -> logical conclusion part)
Sherlock's brother Mycroft is an even bigger genius, but uses his genius for political means. (He might be more an INFJ)
Sherlock is relatable to me in that he gets bored. Of course, I am not the genius sherlock is, but I spent most of my 18 years of education bored. (The only time I wasn't bored was when I was reading books of my own interest.) And most jobs I held during that time. Finally have one that does not seem too boring.
He does weird stuff in his boredom like lock himself in his rooms in his tedium for months on end, and shoots up the wall. In the books he uses opium and smokes a lot.
Sherlock also prefers to be by himself. I don't actually dislike people, but a lot of the time I really prefer to be alone to being around people.
I think the biggest thing that doesn't make sense in the story itself is why he is friends with John

The author had to write a 'relatable' character for the audience and it is so obvious.