It is possible, however, that one violates the prohibition of Kitovet Kaaka on a biblical level only if one’s intention is for idolatry, even according to the opinion of the Chachamim. Recall that the Rambam and Tur write that the reason for the Kitovet Kaaka prohibition is to avoid idolatry. Indeed, the Chatam Sofer (commentary to Gittin 20b s.v. Bichtovet) writes that one does not violate a biblical level prohibition if he tattoos his slave in order that he should not escape (the Shach, Y.D. 180:6, seems to support this view). Maharam Schick (commentary to the Sefer HaMitzvot, Mitzvah 254) and Teshuvot Shoel Umeishiv (2:1:49) agree with the Chatam Sofer.
The Aruch LaNer (commentary to Makkot 21a s.v. Gam Im), on the other hand, asserts that one violates a biblical prohibition even if one’s intention is not for Avodah Zarah (idolatry). The Aruch Laner and Rav Gestetner note that the Rambam and Shulchan Aruch seem to agree with this view, as they do not mention that one violates this prohibition only if his intention is for idolatry. Moreover, Rav Gestetner notes that Tosafot (Gittin 20b s.v. Bichtovet) clearly indicates that a biblical level prohibition is violated even if one’s intention is not for Avodah Zarah.