Solution:
The answer is k=3.
First we show that there is such a function and coloring for k=3. Consider f:Z>0→Z>0 given by f(n)=n for all n≡1 or 2 modulo 3, and f(n)=2n for n≡0 modulo 3. Moreover, give a positive integer n the i-th color if n≡i (mod 3).
By construction we have f(1+2)=6=3=f(1)+f(2) and hence f has property (ii).
Now let n,m be positive integers with the same color i. If i=0, then n+m has color 0, so f(n+m)=2(n+m)=2n+2m=f(n)+f(m). If i=1, then n+m has color 2, so f(n+m)=n+m=f(n)+f(m). Finally, if i=2, then n+m has color 1, so f(n+m)=n+m=f(n)+f(m). Therefore f also satisfies condition (i).
Next we show that there is no such function and coloring for k=2.
Consider any coloring of Z>0 with 2 colors and any function f:Z>0→Z>0 satisfying conditions (i) and (ii). Then there exist positive integers m and n such that f(m+n)=f(m)+f(n). Choose m and n such that their sum is minimal among all such m,n and define a=m+n. Then in particular for every b<a we have f(b)=bf(1) and f(a)=af(1).
If a is even, then condition (i) for m=n=2a implies f(a)=f(2a)+f(2a)=f(1)a, a contradiction. Hence a is odd. We will prove two lemmas.
Lemma 1. Any odd integer b<a has a different color than a.
Proof. Suppose that b<a is an odd integer, and that a and b have the same color. Then on the one hand, f(a+b)=f(a)+bf(1). On the other hand, we also have f(a+b)=f(2a+b)+f(2a+b)=(a+b)f(1), as 2a+b is a positive integer smaller than a. Hence f(a)=f(a+b)−bf(1)=(a+b)f(1)−bf(1)=af(1), which is again a contradiction. Therefore all odd integers smaller than a have a color different from that of a.
Lemma 2. Any even integer b<a has the same color as a
Proof. Suppose b<a is an even integer, and that a and b have different colors. Then a−b is an odd integer smaller than a, so it has the same color as b. Thus f(a)=f(a−b)+f(b)=(a−b)f(1)+bf(1)=af(1), a contradiction. Hence all even integers smaller than a have the same color as a.
Suppose now a+1 has the same color as a. As a>1, we have 2a+1<a and therefore f(a+1)=2f(2a+1)=(a+1)f(1). As a−1 is an even integer smaller than a, we have by Lemma 2 that a−1 also has the same color as a. Hence 2f(a)=f(2a)=f(a+1)+f(a−1)=(a+1)f(1)+(a−1)f(1)=2af(1), which implies that f(a)=af(1), a contradiction. So a and a+1 have different colors.
Since a−2 is an odd integer smaller than a, by Lemma 1 it has a color different from that of a, so a−2 and a+1 have the same color. Also, we have seen by Lemma 2 that a−1 and a have the same color. So f(a)+f(a−1)=f(2a−1)=f(a+1)+f(a−2)=(a+1)f(1)+(a−2)f(1)=(2a−1)f(1), from which it follows that f(a)=(2a−1)f(1)−f(a−1)=(2a−1)f(1)−(a−1)f(1)=af(1), which contradicts our choice of a and finishes the proof.