First, you need to set that KinveyReference to be the value within a `MyEntity` object. In your code, you have an object called `reference` but you will need to set that on an entity. Then, after that, you will need to upload the modified entity to the backend using the save method.
Then, finally, you can do a query for the `MyEntity` and resolve the value of the reference.
take a look at our relational data guide, which might explain these concepts better: