Good question.
There are multiple answers, and they change depending on the type of musical piece you are analyzing, how you analyze it, and probably also from the "school" of thought you believe you belong to...
The most generic definition is probably "musical analysis is that activity that seeks to reconnect any discourse about music to specific characteristics of the music itself". That is, if I want to say that "Fra Martino campanaro" is a beautiful piece, I must do so by reconnecting this statement to specific characteristics of "Fra Martino campanaro".
The definition is generic because when I speak of specific characteristics, I can refer to practically anything: melody, harmony, form, but also text, the metronome, or the sonogram of the singer's voice singing that piece. The elements that can be taken into consideration in an analysis are countless, with methodologies of various natures. But the thing that should always be kept in mind (and many forget) is that a musical analysis should always be linked to a musical DISCOURSE. That is, listing a series of chords, in itself, is not a musical discourse. First, you list the chords and then you explain how they work, what their particularities are, and why they fit so well in that piece. Analysis provides DATA for an aesthetic-type discourse, and this link is the most difficult to discover; it is the beautiful and creative part of an analytical discourse.
From this, one should also understand how analyzing a difficult piece is, absurdly enough, much easier than analyzing an easy piece: a very complicated succession of chords is in itself "richer", allowing us to venture into complex discourses, even if they were only discourses related to harmonic and melodic functions. Analyzing simple pieces with banal chord structures (or always the same ones, as in blues and jazz, for example) is much more difficult. One risks not knowing what to say, or perceiving a beauty by ear that we cannot reconnect to the characteristics of the piece. The same goes for ugliness, eh... I always tell those who criticize Allevi that justifying the ugliness or inconsistency of an Allevi piece through analysis is extremely complicated. This, in my opinion, is one of the greatest limits of musical analysis today. The link between analysis and aesthetic discourse is unprovable and unfalsifiable; that is, with analysis, I can say whatever I want, ESPECIALLY in a positive discourse. This is also the reason why analysis should always be accompanied by very precise historical knowledge. Not just technical, eh. In the eyes of an analyst, a piece by Clementi might seem as complex as a piece by Mozart. But knowledge of contexts, of the artistic values that history has assigned to various authors, of reception, and much more can help to "correct the aim" of analytical evaluations.
It is not easy at all, and it is one of the reasons why there are repertoires for which musical analysis struggles immensely to find keys of interpretation. Baroque music is widely unanalyzed, for example.
P.S.
after reading the messages from Carlos and RStrauss, I would add that obviously musical analysis also serves interpretation. Here, the musical discourse is in a certain sense limited; interpretation can only highlight certain things of a score or a piece, and it is not based solely on analysis (it is also based on practical issues, technical limits, inspiration of the moment, etc., etc.). But the role that analysis has in interpretation is the same as the role it has in a discourse.