Is there a reason the landlord is planning to kick you out for consulting a lawyer? It's unclear why you tie the events together. Has he begun the process of eviction you or were you planning to move?
On a month-to-month lease, the landlord can give notice of termination of lease anytime fifteen days prior to the beginning of the month that will be effective the first of the next month (if you pay rent on the first of the month). The landlord does not have to give a reason for this, but it cannot be Discrimination. The main problem in this scenario would be proving that it was Discrimination. Go see the attorney. Don't tell the manager.
The answer to your question depends on the wording of your lease, if you have one. If you have a lease, you cannot leave before the term of the lease ends, nor can you stay beyond the end of the term of the lease without the landlord's permission. If you are on a month-to-month tenancy, your landlord can give you 15 days notice before the end of a calendar month requiring you to leave at the end of that month. If you are going to consult a lawyer, rely on that lawyer's advice rather that looking for legal advice on an on-line forum.
Disclaimer: This answer is provided for informational purposes only, does not constitute legal advice, and does not create an attorney-client relationship. Actual legal advice can only be provided after completing a comprehensive consultation in which all of the relevant facts are discussed and reviewed.