How would I define mass in a space I always heard that mass is a measure of inertia during my school days. Is this  applicable to bodies which are in space ? Suppose there is space craft in a space; how would I define mass ?
I read some article and consulted with my teachers; they said mass is similar to conservation of momentum but I do not know how. And then he said mass is independent of frame it is constant, whereas I see momentum is itself a frame dependent quantity and velocity is frame dependent. I am confused how I would actually define a mass in space, what is the correct definition for a mass ? 

I am high school boy, I will be thankful if anybody answer my question.
To quote from wikipedia


  There are several distinct phenomena which can be used to measure mass. Although some theorists have speculated that some of these phenomena could be independent of each other,[2] current experiments have found no difference in results regardless of how it is measured:
  
  
  Inertial mass measures an object's resistance to being accelerated by a force (represented by the relationship F = ma).
  Active gravitational mass measures the gravitational force exerted by an object.
  Passive gravitational mass measures the gravitational force exerted on an object in a known gravitational field.
  
  
  The mass of an object determines its acceleration in the presence of an applied force. The inertia and the inertial mass describe the same properties of physical bodies at the qualitative and quantitative level respectively, by other words, the mass quantitatively describes the inertia. According to Newton's second law of motion, if a body of fixed mass m is subjected to a single force F, its acceleration a is given by F/m. A body's mass also determines the degree to which it generates or is affected by a gravitational field. If a first body of mass $m_A$ is placed at a distance $r$ (center of mass to center of mass) from a second body of mass $m_B$, each body is subject to an attractive force $$F_g = Gm_Am_B/r^2$$ where $G = 6.67\times 10^{−11} N kg^{−2} m^2$ is the "universal gravitational constant". This is sometimes referred to as gravitational mass.[note 1] Repeated experiments since the 17th century have demonstrated that inertial and gravitational mass are identical; since 1915, this observation has been entailed a priori in the equivalence principle of general relativity.


In space the third phenomenon (passive gravitational mass) is not terribly useful, because we may not have a known gravitational field to hand, or both the object being measured, and the instruments doing the measuring may be accelerating under the influence of the same field (this is what happens in orbit).

The others are fine. For measurement purposes it can be helpful to avoid having to measure forces exactly, and this is where conservation of momentum comes in. Suppose you have an object of unknown mass $m$ and an object of known mass, which, for simplicity of calculation we'll assume to be 1kg. Initially they are at rest relative to one another. Now we let some interaction happen between them (it doesn't matter what, so long as no other masses are involved) as a result of which they move apart. We measure the speeds of movement (in a frame in which they were both initially at rest), say $u$ for the unknown mass and $v$ for the 1kg mass (these must be in opposite directions). So conservation of momentum tells us that $mu - 1.v = 0$ or $m = v/u$.