No, it can't. Unlike the spell Message, which moves around walls until it reaches your target, Divine Sense cannot function if your target or the thing you are trying to sense has full cover. Being fully behind a wall, without any part of them peaking out, gives your target, be they friend or foe, full cover.