title: creating two models in one serializer of django rest framework
body: <p>During registration of a user I would like to have both a User object and a EmailContact object created in one api call. The two objects should not be linked.
  I have the following serializer:</p>
  
  <pre><code>class RegistrationSerializer(serializers.Serializer):
      userserializer=UserAccountSerializer() #reuse existing modelserializer
      emailcontactserializer=EmailContactSerializer()  #reuse existing modelserializer  
  
      def create(self, validated_data):
          emailcontact_data = validated_data.pop('emailcontactserializer')
          user_data = validated_data.pop('userserializer')
          emailcontact= EmailContact.objects.create(**emailcontact_data)
          user= User.objects.create(**user_data) 
          return user 
  </code></pre>
  
  <p>and the following Apiview:</p>
  
  <pre><code>class RegistrationAPIView(APIView):
      permission_classes = (AllowAny,)
      serializer_class = RegistrationSerializer
  
      def post(self, request):
          serializer = self.serializer_class(data=request.data)
          if serializer.is_valid():
              serializer.save()
              return Response(serializer.data, status=status.HTTP_201_CREATED)
          return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)
  </code></pre>
  
  <p>The error I get is the following (occurs after the serializer.save()):</p>
  
  <p><strong>AttributeError at /api/register</strong>
  Got AttributeError when attempting to get a value for field <code>userserializer</code> on serializer <code>RegistrationSerializer</code>.
  The serializer field might be named incorrectly and not match any attribute or key on the <code>User</code> instance.
  Original exception text was: 'User' object has no attribute 'userserializer'.</p>