The structure of a small category is a quiver - every vertex of the quiver represents an object with its identity morphism, and the edges of the quiver represent the non trivial morphisms (I know you can define it such that the identity morphisms are edges too, but it's more elegant this way imo). In other words, there is a forgetful functor from the category of small categories to $\mathbf{Quiv}$. My question is, what is the image of this functor? Namely, given any quiver, can we determine if exists a category of this structure?
The answer to the question whether exists a free category with the structure of a given quiver is very simple: we can just look at the free category generated by the quiver, and see whether we had to add arrows or not. But when we talk about the structure of categories that are not free, there isn't a simple criterion like that. For example, this quiver is a structure of a category, but this is not (as explained here).
This is only a partial answer.
A quiver $Q$ is given by a pair of sets $E, V$ and a function $\langle s, t \rangle: E \to V \times V$. The image of the function is a subset $R \hookrightarrow V \times V$, i.e., a relation on $V$, with an epi $\pi: E \to R$ given by $\pi(e) = (s(e), t(e))$.
A sufficient condition for $Q$ to be the underlying quiver of a category (removing identities) is for $R$ to be transitive. To see this, choose a section $\sigma: R \to E$. Suppose given edges $f: u \to v$ and $g: v \to w$ in $E$. Since $(u, v) \in R$ and $(v, w) \in R$, transitivity yields $(u, w) \in R$; in view of this, define $gf = \sigma(u, w)$. Associativity is immediate, for all composable chains $t \to u \to v \to w$ of arrows in $Q$, since either bracketing leads to $\sigma(t, w)$. Then freely adjoin identities to get a category whose underlying quiver is $Q$.
Transitivity of $R$ is not a necessary condition for $Q$ to underlie a category. It's necessary that $a \leq b$ and $b \leq c$ in $R$ implies $a \leq c$ whenever $a \neq c$. The only times transitivity of $R$ could fail is when there are arrows $f: u \to v$ and $g: v \to u$ but no non-identity arrow $u \to u$ in the originating category. This would in turn force the condition $g f = 1_u$ for any two arrows $f: u \to v$ and $g: v \to u$, and it places further conditions on the sizes of hom-sets in the category; for example, $|\hom(x, u)| \leq |\hom(x, v)|$ for all vertices $x$ (since composition with any $v \to u$ retracts $\hom(x, v)$ onto $\hom(x, u)$). Similarly, $|\hom(u, x)| \leq |\hom(v, x)|$. It's not yet clear to me whether all these conditions suffice to guarantee that $Q$ underlies a category structure.