Could I use other Collections in mongo $function (v4.4)?

My example, please help me.

CollectionName.aggregate( [
   { $addFields:
      {
         message:
            { $function:
               {
                  body: function(name) {
                     let data = OtherCollection.findOne({....})
                     ................

                     return data
                  },
                  args: [ "$name"],
                  lang: "js"
               }
            }
       }
    }
] )