Bei is neither "near" nor "next to" except maybe in very specific contexts. Don't get that confused with the English word "by". Near would be nah, and next to would be neben.
Bei, however, translates specifically to "at the place of". If you say you are "bei diesem Haus" you are saying you are "at the place of this house." Which basically means you are somewhere on the property. Bei is often used when a location is represented by a concept, for instance "I am at the concert" (Ich bin beim Konzert). The concert is an event being held at a specific place, so you want to say that you are at the place where the concert is being held. Of course bei also refers to physical places, like on the property of a house, or quite often you might say "bei jemandem" to say that you are at the place of somebody, or more specifically that you are at their home.
Oddly enough, there are communities in the U.S. (mostly of German heritage) that DO use "by" to mean "at." I've always found it a bit weird, but have heard it often enough now to know what they mean. For example, they might say, "We were by Linda's last night," to mean they visited Linda in her house, not that they drove past her house, or that they stood awkwardly on the front lawn outside her house without being invited in. :). I still wouldn't consider it proper English, certainly not for writing.
I think when you're talking about a house, "bei" must be used (in the same way "an" is used with the word "Ort" or "in" with "Straße").
Ich bin bei Peter = I'm at Peter's.
What I don't know is if "in" can be used here (with houses and such) "Gestern war ich in jedem Haus. Peter wohnt da. " is this sentence correct??
"Er ist zu diesem Haus"? -That's not possible.
- Er ist zu diesem Haus gefahren/gegangen. you will need a movement-verb. = He went to the house.
- Er ist bei diesem Haus. = He is at the house.
- Er rennt bei der alten Eiche. = He is running near the old oak. (I only want to show you 'bei' is a preposition which tells something is in, at, near something.)
Not quite; possession would be the genitive case, which often includes an „-s“ being attached to the end of the article and/or noun.
The dative case is used when you need an indirect object; certain prepositions are accusative (require direct objects) in German, while others are dative (require indirect objects). The preposition „bei“ is one of the dative prepositions
That's the wonder of prepositions when you learn different languages; there is rarely a one-to-one correspondence. One preposition in English could have many different translations in German depending on context. Here is an article that might help: https://www.thoughtco.com/german-preposition-bei-1444459
as far as I know when we talk about people or specific things we use "bei", but not in case we refer to places like house, mall and so on. For instance, it should be "zu Hause" for expressing sth or someone "at house" up to what I have been taught. Why did we use "bei" here?