Every conductive material imposes a certain amount of resistance per unit length. The amount of resistance can be measured by a multimeter and depends on a number of factors such as temperature, width, material, etc. A resistor, in traditional electronics, is used to limit the voltage provided to a particular part of your circuit (because Voltage = current * resistance).
Making Resistors with Conductive Thread
In traditional electronics, you typically purchase resistors of set values that you need. In soft electronics, you can make your own resistors by simply measuring the amount of resistance of a conductive thread of a given length and cutting a length long enough to provide the total amount of resistance you need. More resistance, longer length. For less resistance, cut. The key is that you have to find a way to integrate that length of yarn into your project in the region it is needed and you must ensure that, in order to get the resistance you require, the length of string does not cross itself. If crossing does happen, the electricity will follow the path of least resistance, and provide a much lower value of resistance than you require. (However, this same principle can be really useful when making resistive sensors). Since you can find conductive yarns in a wide range of resistance values, you can use these measures to balance against length. For instance, a higher resistance material will require a shorter length to obtain a certain resistance value than a lower resistance material.
For weaving resistors, its common to simply throw a conductive/resistive yarn every so many pics so that it is sure not to touch. I find throwing every 2 pics is typically good enough to prevent shorts.
Knitting resistors can be accomplished by carrying-along a resistive yarn with the knitted structure or replacing certain rows with a resistive material. Ebru Kurbak provides a nice detail on how knitted resistors were accomplished in the Knitted Radio project: https://ebrukurbak.net/the-knitted-radio/