Ants on your lemon tree are likely a sign that your lemon tree has scale and/or aphids. The ants aren't causing any damage to the tree, but sometimes they "farm" the aphids or scale insects because both of these pests produce honeydew, a sweet, sticky, saplike substance that the ants eat. If aphids are present, control can be relatively easy. Aphids may be washed off the tree with a forceful spray of water, or killed with insecticidal soap.
Scale insects are much more difficult to control because they are protected under their hard, shell-like armor for most of their lives. To control them, it's important to time insecticide sprays when the crawlers (newly hatched scale insects) are active, and before they develop a hard shell.