Looking at the documentation for input parameters for obsidian-tracker, I suspect that datasetName is what is actually making the legend labels. For each searchTarget in your graph, make sure you also have set a datasetName.
The page I linked before also shows which “legend”-related options exist. Good luck!
It looks like there are settings for “legendPosition” and “legendOrientation” - I do not know if either of those would help. To make the whole graph bigger there are “fitPanelWidth”, “fixedScale” and “margin” parameters which all go before the graph type. I like setting fitPanelWidth: true for my line graphs, maybe that will work for you?