I was oversimplifying, I guess. Lawyers will generally tell you what law something may violate but they will offer context. Something can be legal or illegal depending on what information is available. A
good lawyer will tell you not only whether something could technically be considered a crime but will also give you feedback on how to avoid doing that (which may change nothing about the actual thing you plan to do, just how you go about it).
If something is criminal is decided in court. A lawyer advises on how likely the court is to decide that way.