The default names of measurements that are performed (and not opened from file) can be changed from Plot->Layout->Text Refreshing... as shown below.
Measurements that are opened from a file are given the same name as the filename. As shown in the figure above, you can select if you want to add the folder name and/or file extension to the filename.
A way of changing the name is to save the file, then the new filename will be displayed in the legend. Alternatively the default names of the curves in the legend can be changed from Plot->Layout->Edit.... Select the curve you wish to rename. In the figure below, Meas. 5 is selected. Then click the button and type the new name.
Note: The new names will not be remembered, which means that they will be lost when the curves are deleted or refreshed.