Of-course. That is how we progress our understanding. Quite often there is a "tug of war" type conflict over whether an existing, preferred, theory can accommodate conflicting observations or whether a new theory is needed.
It is possible, hypothetically at least, that we find more than one theory that explains a set of observations, in which case we decide on which one to use, using a set of rules: Occam's razor, consistency with other theories and so on. Sometimes once school "wins" this battle for political reasons, temporarily, until more observations confirming or finally refuting the theory are found.
In all cases we are dealing with models of what seems to be an underlying reality, actual reality remains too slippery to get a hold of. The model may be perfectly useful and usable even if it is later superseded because of better observations or because a more widely applicable theory turns up.
As NS mentioned, Kuhn is our man here:
https://en.wikipedia.org/wiki/Thomas_KuhnAnother, separate, point is that although we describe science as a process, performing this process like an algorithm sometimes just gets us stuck in loops or knots - to make progress and answer intractable problems often a sudden leap or new direction, based on intuition or imagination, must be taken.