What is the definition of a measurable set?

There is no universal and objective definition of what is a measurable subset of a general space $X$. The general concept of a measurable subset has its origins in the problem of measure in Euclidean space:

Problem of measure: Given an object $A\subset\mathbb R^n$, how does one assign a measure $m(A)\in[0,\infty]$ to $A$? (In the case $n=1,2$ and $3$, the measure $m(A)$ is traditionally referred to as the length, the area, and the volume of $A$, respectively).

When the objects considered are very simple, this question is very easy to answer. For example, given a line segment $A=[a,b]\subset\mathbb R$, the measure of $A$ should obviously be of $m(A)=b-a$. Given a $n$-dimensional rectangle $$A=[a_1,b_1]\times\cdots\times[a_n,b_n]\subset\mathbb R^n,$$ the answer is equally obvious: $$m(A)=\prod_{i=1}^n(b_i-a_i).$$ Then, one can easily extend the measure of rectangle to slightly more general sets, such as disjoint unions of rectangles $$A=R_1\dot\cup\cdots\dot\cup R_k$$ by assigning $$m(A)=\sum_{i=1}^km(R_i)$$ (Indeed, for a theory of measure to make any kind of geometrical sense, the measure of a union of disjoint parts should be the sum of the measures of the constituent parts.) The real problem comes when trying to measure more complicated subsets of $\mathbb R^n$.


A classical solution to the measure problem consists in attempting to approximate the measure of a complicated set using simple sets. More precisely, suppose we have a class of simple sets $S$ which we know how to measure (these would contain rectangles and finite unions of rectangle for example). Then, given some arbitrary set $A$, we can define an inner measure $m_I(A)$ and an outer measure $m_O(A)$ of $A$ by letting $$m_I(A)=\sup\{m(E):E\subset A,~E\in S\}\text{ and }m_O(A)=\inf\{m(E):E\supset A,~E\in S\}.$$ (Note that the inner and outer measures of sets in $S$ are clearly the same as the measure we have already assigned to them.) In this framework, one calls a set $A\subset\mathbb R^n$ measurable if $m_O(A)=m_I(A)$, in which case we assign $m(A)=m_O(A)=m_I(A)$. In other words, we call a set measurable if our theory of measure is capable of giving a sensible answer to "what is the measure of $A$?"


The solution of the measure problem I discussed in the previous paragraph gave rise to the Jordan theory of measure, as well as the more modern Lebesgue measure. The concepts of outer measure and general measures you have written down in your questions are answers to generalizations of the problem of measure to arbitrary spaces $X$, with the intent of extending the theory of Lebesgue integration to those spaces. The exact axioms (i.e., the definitions of a $\sigma$-algebra and measure) are in place in order to ensure that we obtain a theory of integration that is similar to the theory of Lebesgue measure/integration, that is, with similar theorems such as countable subadditivity, countinuity from above/below, monotone/dominated convergence, etc.


Going into more detail would require a lot of explanation. If you'd like to know more, I personally recommend reading sections 1.1 - 1.4 of An introduction to measure theory by Terence Tao. I only really started to understand measure theory when I read it.