How does an electron identify whether to absorb a photon of a certain wavelength or not in absorption spectrum?
[OP..] How would an electron identify the specific photons of a certain wavelength which are to be absorbed in a Hydrogen atom while creating an absorption spectrum?

As discussed in the comments, this is an observed phenomenon. We can try to describe this observation in a way that we can make predictions, but that does not answer the questions &quot;how?&quot;.

[OP..] Otherwise, it cannot find a shell and since electrons cannot exist in between shells, they simply re-emit that photon and we perceive the incident as if the photon weren't absorbed at all.

There are processes that do something similar as the one you describe, but they involve observable events. When an atom scatters light, it scatters light of the same wavelength as the incoming light, but in all directions. There are also processes where the light is absorbed and then emitted again after a while (sometimes at different wavelength). What you suggest is an explanation for observing no interaction between the electron and the photon, and explaining it with an interaction (absorption and instant re-emission at the same wavelength in the same direction) that we can't observe.
You could have explanation models of the same flavor for many things that don't happen. For example, on a day it does not rain, I could say drop form in the clouds but instantly are destroyed again, so we can't observe them ever.

Way-02: The explanation given above is false and electrons choose the photons via some other mechanism

As you can read in the comments, using the term &quot;choose&quot; for something electrons do is not so helpful. We know under what conditions the photon might get absorbed (not all of them are), but to go beyond that and explain the &quot;how&quot; or even &quot;why&quot; is difficult to impossible (and not taught in e.g. the 4-year college chemistry curriculum, as far as I know).