I agree with you. These definitions seem to be a little sloppy.

First, to be fully precise, one must talk about free or boundoccurrencesof a variable. A given occurrence of x is bound if it occurs under λx and is free otherwise. A less precise statement "x is free in E" means that there is a free occurrence of x in E, and similarly for bound. Note that one variable can have both free and bound occurrences in the same expression.

For a thorough account see "Lectures on the Curry-Howard Isomorphism," chapter 1. It even formally introduces alpha-equivalence (the renaming of bound variables) whereas most other sources just say informally that terms obtained from each other by the renaming of bound variables are identified. See also the classic text "Lambda Calculi with Types" by Henk Barendregt. If you need more textbook recommendations, let us know.