At present, the find definition/declaration function only allows searching by position but Merlin is perfectly capable of searching for identifiers (locate-ident or occurrences with prefix).
Even though it's not particularly protocol-compliant, I suggest (on behalf of @catern, tarides/ocaml-eglot#72 (comment)) adding an optional field in the references request to pass a prefix.
Since the parameter is optional, it does not disrupt the usual functioning of the query and allows Emacs to have a more refined xref backend that does not rely on tunneling (merlinCallCompatible).