It doesn’t, because this is presentation layer responsibility, not data layer (Ecto) or just (de)serializer (Jason). If you want to handle missing data, then do it on your own.
Yes it would be and probably the best way to represent that in a JSON object is by not including the key at all. That solution requires the custom instance on your Ecto model, or if you are using Phoenix just do it the recommended way that you see in phx.gen.json: render functions that map your schema struct records to naked maps.
In general the advice is to use Map.take and not Map.drop because Map.take is much much safer. If you add a new field that contains sensitive information to your schema, the Map.drop approach makes that information available by default. This is very bad. Instead be conservative and list the things you want to serialize.